Hi peeps.
I'm having a few difficulties getting a table to display all the proper info once it has finished being searched etc.
I'm having particular problems with a cell at the end of the results table which displays an image if there is an audio sample avavailable for that particular item.
Here's the code for the table cell[VBS] <table width="100%" cellspacing="2" align="center">
<tr bgcolor="#666666">
<td width="52">
<center>
<font color="#FFFFFF"><b>Cat no.</b> </font>
</center>
</td>
<td width="99">
<center>
<font color="#FFFFFF"><b>Artist</b> </font>
</center>
</td>
<td width="96">
<center>
<font color="#FFFFFF"><b>A Side</b> </font>
</center>
</td>
<td width="96">
<center>
<font color="#FFFFFF"><b>B Side </b> </font>
</center>
</td>
<td width="96">
<center>
<font color="#FFFFFF"><b>Label</b> </font>
</center>
</td>
<td width="44">
<center>
<font color="#FFFFFF"><b>Year</b> </font>
</center>
</td>
<td width="60">
<center>
<font color="#FFFFFF"><b>Price (£</b> </font>
</center>
</td>
<td width="94">
<center>
<font color="#FFFFFF"><b>Info</b> </font>
</center>
</td>
<td width="48"> </td>
</tr>
<tr bgcolor="#666666">
<td colspan="9" bgcolor="#000000" height="1">
<center>
<img src="images/divider.jpg" width="740" height="1">
</center>
</td>
</tr>
<% Do While not rs.eof %>
<tr>
<td width="52" valign="middle"><%=rs("catno")%></td>
<td width="99" valign="middle"><%=rs("artist")%></td>
<td width="96" height="15" valign="middle"><%=rs("aside")%></td>
<td width="97" valign="middle"><%=rs("bside")%></td>
<td width="115" valign="middle"><%=rs("label")%></td>
<td width="44" valign="middle">
<center>
<%=rs("year")%>
</center>
</td>
<td width="60" valign="middle">
<center>
<%If True = rs("reserved") Then
Response.write "<font color=yellow>Reserved</font>"
Else
Response.Write rs("price")
End If
%>
</center>
</td>
<td width="94" valign="middle"><%=rs("notes")%></td>
<td width="48" valign="middle">
<center>
<% If rs("sample") = "True" Then %><a href="samples/<%= rs("samplename") %>"><img src='images/small_speaker.jpg' width='18' height='15'border= '0'></a><% End If %>
</center>
</td>
</tr>
<tr valign="middle">
<td colspan="9" height="1">
<center>
<img src="images/divider.jpg" width="740" height="1">
</center>
</td>
</tr>
<% rs.movenext
loop
%>
</table>
</center>
</td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td> </td>
</tr>
</table>
<% end if 'end of check of obs for display %>[/VBS]
The problem I'm having is for example, 10 results were found, only the first row of the table displays the image (which is in fact a link to the audio sample) and then the other rows in the table are ignoring the If Else statement and displaying nothing.
Any ideas anyone?
Matt
PS.... dunno why the smiley appeared in the code
PPS....I'm referring to the line that reads:[VBS]<% If rs("sample") = "True" Then %><a href="samples/<%= rs("samplename") %>"><img src='images/small_speaker.jpg' width='18' height='15'border= '0'></a><% End If %>
[/VBS]



</b> </font> 

Bookmarks