Empty element efect my table view.....

wxdqz

New Member
Hello !!

I have a problem creating a table when some times the elements are empty .
the internal border of the empty cells are not the same as the rest of the internal borders !!!!

Is the any way to fix it with XSL or HTML code ? i want it to look the same all the time !!!!

is it a code like ::
<table .... border.... cell.... ...> ??????

My xml is :

<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href=http://www.webdeveloper.com/forum/archive/index.php/"xsl.xsl"?>
<Users>

<user>

<Name>

<FirstName>uu</FirstName>

<LastName>uup</LastName>

</Name>

<ID>654869753</ID>

<Address>

<city>NY</city>

<Street>CRT</Street>

<Number>9</Number>

<TD>8996787499</TD>

</Address>

<Novel>

<LogInName></LogInName>

<Password></Password>

</Novel>


<LGPC>

<LogInName></LogInName>

<Password></Password>

</LGPC>

<Food type="Babushka">All the time</Food>

</user>

<user>

<Name>

<FirstName>ano</FirstName>

<LastName>nimi</LastName>

</Name>

<ID>024567895</ID>

<Address>

<city>akko</city>

<Street>lech lech</Street>

<Number>796</Number>

<TD>17643</TD>

</Address>

<Novel>

<LogInName>upltm00</LogInName>

<Password>kuskus11</Password>

</Novel>

<LGPC>

<LogInName>anon</LogInName>

<Password>78bl90</Password>

</LGPC>

<consule>

<LogInName>anono</LogInName>

<Password>meepmeep</Password>

</consule>

<Food type="Babushka">20:15</Food>

</user>

</Users>



My xsl is :

<?xml version="1.0"?>

<!-- File Name: test.xsl -->

<xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">

<xsl:template match="/">

<TABLE BORDER="20" CELLPADDING="15" bgcolor="Deepskyblue">
<THEAD>
<TH><font color="red" size="5">Name</font></TH>
<TH><font color="red" size="5">Id</font></TH>
<TH><font color="red" size="5">Address</font></TH>
<TH><font color="red" size="5">Novel</font></TH>
<TH><font color="red" size="5">LGPC</font></TH>
<TH><font color="red" size="5">Food</font></TH>
</THEAD>
<xsl:for-each select="Users/user">
<TR ALIGN="left">
<TD>
<xsl:value-of select="Name/FirstName"/>
<xsl:value-of select="Name/LastName"/>
</TD>
<TD>
<xsl:value-of select="ID"/>
</TD>
<TD>
<xsl:value-of select="Address/city"/>
<BR/>
<xsl:value-of select="Address/Street"/>
<BR/>
<xsl:value-of select="Address/Number"/>
<BR/>
<xsl:value-of select="Address/TD"/>
</TD>
<TD>
<font color="Firebrick"></font><xsl:value-of select="Novel"/>
<BR/>
</TD>
<TD>
<xsl:if match =".[LGPC/LogInName !='']">
<font color="Firebrick"></font><xsl:value-of select="LGPC"/>
</xsl:if>
</TD>
<TD>
<xsl:value-of select="Food"/>
</TD>
</TR>
</xsl:for-each>
</TABLE>
</xsl:template>
</xsl:stylesheet>


thanks
 
Top