Getting previous page url
Posted: Thu Dec 11, 2008 4:43 am
hi,
i am having a page on which i check if the user is logged in. if the user is logged in i save some details in the db and display a link for the user. on clicking this link a pdf/html page is opened.
Now when the user preses the back button of the browser, he is taken back to the same page, where it checks that the user is logged in and again saves details to the db.
I tried using HTTP_REFERER to check if the url of the link and that of the previous page is same, but HTTP_REFERER does not give me the link of the pdf since the user is using back button.
Is there a way to get the url of the previous page in this case
i dont want to disable the browser button or anything
Thanking in advance.
i am having a page on which i check if the user is logged in. if the user is logged in i save some details in the db and display a link for the user. on clicking this link a pdf/html page is opened.
Now when the user preses the back button of the browser, he is taken back to the same page, where it checks that the user is logged in and again saves details to the db.
I tried using HTTP_REFERER to check if the url of the link and that of the previous page is same, but HTTP_REFERER does not give me the link of the pdf since the user is using back button.
Is there a way to get the url of the previous page in this case
i dont want to disable the browser button or anything
Thanking in advance.