Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Code Support: ASP (Non-Forum Related)
 Oh I know this is really basic, but I need help...
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Roland
Advanced Member

Netherlands
9335 Posts

Posted - 09 May 2002 :  17:16:49  Show Profile
As the subject says, I know it's really basic but my ASP skills seriously lack in this case (and most other cases) so I hope someone is willing to help me out here.

What I want to do: Create a page with a table where certain information is displayed. Like this:
-----------------------------------
|Title | | |
-----------------------------------
|Title of the movie | img1 | img2 |
-----------------------------------
|Title of the movie | img1 | img2 |
-----------------------------------
|Title of the movie | img1 | img2 |
-----------------------------------
|Title of the movie | img1 | img2 |
-----------------------------------
|Title of the movie | img1 | img2 |
-----------------------------------


What I can't do: I don't know how to get the rows filled up with the correct information so people can go to the sub-page (done by clicking on the title or img1) or to the movie's page on Amazon.com (by clicking on img2).

What I have: This is what I use to get the information from the database (database connection is independant of the forums and it's strConnString is defined):

set Dvds_Manager = Server.CreateObject("ADODB.Recordset") ' Creates the RecordSet
Dvds_Manager.ActiveConnection = My_strConnString


Dvds_Manager.Source = "SELECT DVDID, TITLE, SITE FROM DVDS"

Dvds_Manager.CursorType = 0 'adOpenForwardOnly
Dvds_Manager.CursorLocation = 2 ' adUseServer
Dvds_Manager.LockType = 3 ' adLockOptimistic
Dvds_Manager.Open()


strThisDvdId = Dvds_Manager("DVDID")
strThisTitle = Dvds_Manager("TITLE")
strThisSite = Dvds_Manager("SITE")


Can anyone tell me how I can get the information in a neat table? I'm not 100% sure about the line in red, but it should work as I only need those three fields called. The other fields are used on the sub page.

Thanks,



http://www.frutzle.com

Snitz Exchange | Do's and Dont's

Nathan
Help Moderator

USA
7664 Posts

Posted - 09 May 2002 :  18:42:20  Show Profile  Visit Nathan's Homepage
I assume that "SITE" is the link to amazon.

<% do untill Dvds_Manager.EOF %>
<tr>
<td>
<%=Dvds_Manager("TITLE")%>
</td>
<td>
<a href="details.asp?id=<%=Dvds_Manager("DVDID")%>"><img1 /></a>
</td>
<td>
<a href="details.asp?id=<%=Dvds_Manager("SITE")%>"><img2 /></a>
</td>
</tr>
<% Dvds_Manager.movenext
loop%>


That might get ya started. . .

Nathan Bales
Snitz Exchange | Do's and Dont's
Go to Top of Page

Roland
Advanced Member

Netherlands
9335 Posts

Posted - 09 May 2002 :  18:59:20  Show Profile
Hmm... well it shows something, but it keeps repeating the first item in the database.

Never mind. I fixed the problem and it was something on my side.
It's working now. Thank you very very much Nathan.



http://www.frutzle.com

Snitz Exchange | Do's and Dont's

Edited by - frutzle on 09 May 2002 19:07:38
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.21 seconds. Powered By: Snitz Forums 2000 Version 3.4.07