D
Dave Ortman
I'm sure this has got to be a simple problem to get around, but for some
reason the simple solution is eluding me.
I have a JSP page that's simply showing data. I fetch the data from the
database, place it in a few beans, then pass that to a JSP page which
displays the data in a few tables. Some of the fields queried from the
database are empty, so I'm returning empty strings. The result is that the
border for the table is not being drawn, as the cell is empty.
None of the ideas of getting around this seemed ideal:
1. Pad each table cell with a " " (in addition to whatever JSP tags are
in that cell). That way, if nothing is returned from the JSP tag, the cell
still has some content.
2. Manually place the " " in the bean when I'm querying the
database.... that's not right.
3. Write a JSP filter to located empty table cells and insert a " ".
That seems heavy handed.
4. Make each JSP tag an if statement that checks the length of the value
it's displaying. If it's zero, then write " " instead of the bean
value.
None of these seem ideal. Does anyone have the simply solution, which I
must be overlooking?
Thanks,
-Dave
reason the simple solution is eluding me.
I have a JSP page that's simply showing data. I fetch the data from the
database, place it in a few beans, then pass that to a JSP page which
displays the data in a few tables. Some of the fields queried from the
database are empty, so I'm returning empty strings. The result is that the
border for the table is not being drawn, as the cell is empty.
None of the ideas of getting around this seemed ideal:
1. Pad each table cell with a " " (in addition to whatever JSP tags are
in that cell). That way, if nothing is returned from the JSP tag, the cell
still has some content.
2. Manually place the " " in the bean when I'm querying the
database.... that's not right.
3. Write a JSP filter to located empty table cells and insert a " ".
That seems heavy handed.
4. Make each JSP tag an if statement that checks the length of the value
it's displaying. If it's zero, then write " " instead of the bean
value.
None of these seem ideal. Does anyone have the simply solution, which I
must be overlooking?
Thanks,
-Dave