There are also filters that can be used to compress the page as it is being sent to the browser.
You can also try writing out tags differently to minimise spaces produced in source eg
<logic:iterate ... ><tr ... ><logic:iterate ... ><logic:equal name="colCount" value="0" ><td ... ><!-- last name --><a ...> <bean:write ... /></a></td></logic:equal
... ... ...</logic:iterate </tr></logic:iterate>
The spaces inside a tag will not be output to the page. So by putting the indentations there, you can see them in the code but not the html that is sent to the browser.
Eg
<logic:iterate ... >abc</logic:iterate>
will produce
'abcabcabcabc'
where as
<logic:iterate ...> abc </logic:iterate>
will produce
' abc abc abc abc'
JoAnn Lemm wrote:
Hey All,
I'm wondering if anyone else is seeing this impact. I've got an iterator within an iterator thusly:
<table border='1' cellpadding='0' cellspacing='0' style='BORDER-COLLAPSE: collapse' bordercolor='#111111'> <logic:iterate id="rowArray" name="batchForm" property="rowBatchDetails" indexId="rowCount"> <tr align="center" bgcolor='<%=rowCount.intValue()%2==0?"#ffffff":"#dddddd"%>'> <logic:iterate id="colArray" name="rowArray" indexId="colCount">
<logic:equal name="colCount" value="0"> <td align='left' width='165' class='normaltxt' height="20"> <!-- last name --> <a HREF="batch.do?action=Prospect&prospectChoice=<%=rowCount%>" target="_top"> <bean:write name="colArray" /></a> </td> </logic:equal>
<etc ...>
</logic:iterate> </tr> </logic:iterate> </table>
The resulting html looks like the following. Note all the empty spaces. Needless to say, this has impacted performance on the website significantly by increasing the size of the page to something ludicrous when I have more than 20 rows with 10 columns of data to display! Anyone have a solution for this? A patch somewhere? Do I resort to using *gasp* scriptlets?
<table border='1' cellpadding='0' cellspacing='0'
style='BORDER-COLLAPSE: collapse' bordercolor='#111111'> <tr
align="center" bgcolor='#ffffff'>
<td align='left' width='165' class='normaltxt' height="20">
<!-- last name -->
<a HREF="batch.do?action=Prospect&prospectChoice=0"
target="_top">
Aiken</a>
</td>
<td align='left' width='150' class='normaltxt' height="20"> <!--
first name-->
<a HREF="batch.do?action=Prospect&prospectChoice=0"
target="_top">
Glenda</a>
</td>
<and more of the same ...>
JoAnn Lemm
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Jason Lea
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]