Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Oct 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Lightbulb <a href problem... help pls

    my default.asp codes

    <%
    dosyayolu = Server.MapPath("urunler.mdb")
    Set conn = Server.CreateObject("ADODB.Connection")
    conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & dosyayolu

    Set rs=conn.Execute("select*from urunler order by urunID Asc")

    dim sayac
    sayac = 4
    Do until rs.EOF

    if sayac= 4 then
    Response.Write "<tr>"
    sayac = 0
    end if
    Response.Write "<td>"
    Response.Write "<table align=left cellpadding=2 "
    Response.Write "cellspacing=0><tbody>"
    Response.Write "<tr>"
    Response.Write "<td align=center><A HREF=""productDETAIL.asp?urunID=" & rs("urunID") & """><IMG src="&rs("urunRESIM")&" width=130 height=140></A></td>"
    Response.write "</tr>"
    Response.Write "<tr>"
    Response.Write "<td align=center>"&rs("urunADI")&"</td>"
    Response.write "</tr>"
    Response.Write "<tr>"
    Response.Write "<td align=center>"&rs("urunFIYATI")&"</td>"
    Response.write "</tr>"
    Response.Write "</tbody></table><p>"
    Response.Write "</td>"
    if sayac= 4 then
    Response.Write "</tr>"
    end if


    rs.MoveNext
    sayac = sayac + 1
    Loop

    rs.Close()
    Set rs = nothing
    %>

    and this is my productDETAIL.asp codes
    <%
    id = Request.QueryString("urunID")
    dosyayolu = Server.MapPath("urunler.mdb")
    Set conn = Server.CreateObject("ADODB.Connection")
    conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & dosyayolu
    Set rs = Server.CreateObject("Adodb.Recordset")
    sql = "Select * FROM urunler WHERE urunID= '" & id & "' "
    %>

    default.asp page is working correctly but when i click a product link

    http://www.cemoflower.com/asp/produc....asp?urunID=63

    it's loading but the page is empty. No picture no error only blank.

    How can i show the choosen products to productDETAIL.asp page ?

  • #2
    Regular Coder Cipher's Avatar
    Join Date
    Dec 2004
    Posts
    123
    Thanks
    0
    Thanked 0 Times in 0 Posts
    if the ID Column DataType is Integer, do not use single quote '', make it like this:
    sql = "Select * FROM urunler WHERE urunID= " & id & " "


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •