Web Analytics Made Easy -
StatCounter Set position in table - CodingForum


No announcement yet.

Set position in table

  • Filter
  • Time
  • Show
Clear All
new posts

  • Set position in table

    Hi all

    I have a long table (<table> ... <tr> ... etc) which is filled from a database. The IDs of the records are linked to a other asp which does some stuff. How can I go back to the same position on the list back? I can't use browserback because I need an update of the list.asp before.


  • #2
    I think there's a few questions in here.

    To always get an updated version of a page, you can control cache by writing HTTP headers in ASP.

    But... if I understand you right, what you're after is:

    You generate table rows. Each row represents one data record. You link to another page from each row - presumably you're passing that row's ID through?

    (as in <a href="otherpage.asp?ID=<%=intCurrentRecordId%>">linky</a>)

    So put an <a name> tag in that table row, and when you return the user from otherpage.asp, go to originalpage.asp#<%=intPassedRecordId%>


    • #3

      Thanks for your answer.

      So I have to put <a name=" & <% rs("ID") %> behind the <tr>-Tag?


      • #4
        Don't know if I'm correct, but looks like he meant something more like this

        Make an anchor for the record:
        <a name="<%=rs("ID")%>"></a>

        So the link back to it would be

        <a href="origpage.asp#<%=rs("ID")%>">Go Back</a>

        I guess you could put the anchor anywhere in the same row, I would put it right behind a link.
        <a href="detailpage.asp" name="<%=rs("ID")%>">Link</a>
        Last edited by graficus; Sep 29, 2006, 11:50 PM.
        I know that I know nothing


        • #5
          Thanks - it works fine now