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 3 of 3
  1. #1
    New Coder
    Join Date
    Aug 2002
    Location
    Jacksonville, NC
    Posts
    48
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question help with document.referrer

    Hello all,
    Im designing a website where I want each page to display a trail of crumbs, that is all the pages that the user went through to get to the current one. It would look something like
    Education->Universities->Professors


    In other words, I want each page that is linked to, to be able to display the name of the page that referred to that page. I have tried using document.referrer, but I dont get anything.

    What am I doing wrong and what should I do to make this work?

    Please help
    Genius has to have a starting point

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    New York, USA
    Posts
    175
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Typically bread crumb scripts are not written to display the pages you just came from, but the directory structure of the site... so you can dig into a certain area for instance, but then jump back out to various levels from the home page. Like Codingforums.com.

    Although they are typically written on the server side, you can do it in javascript. this article has some info http://www.evolt.org/article/Breadcr...ript/17/15480/

    If I wanted to create a script that tracked (and listed as links) the previous three or so pages visited, I would pass the page urls through the query string and adjust that data at each new page. Is that what you want to do? Or is it the former?

  • #3
    New Coder
    Join Date
    Aug 2002
    Location
    Jacksonville, NC
    Posts
    48
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi boywonder,


    It is the latter that I want to do, to display a list of all th pages Ive been tbefore I linked to the current one. This would work like the list that they display in yahoo whenever you search for stuff and then navigate deeper and deeper.Also I want each of those crumbs to act like links so I can click on them to navigate back.

    how do i do that?
    Genius has to have a starting point


  •  

    Posting Permissions

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