thebestone Posted June 7, 2007 Share Posted June 7, 2007 Is it possible to get the page anchor name when using $_SERVER['HTTP_REFERER'];? So instead of mysite.com/one.html it'll show mysite.com/one.html#two Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/ Share on other sites More sharing options...
trq Posted June 7, 2007 Share Posted June 7, 2007 I would think $_SERVER['REQUEST_URI'] would hold that. Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/#findComment-269993 Share on other sites More sharing options...
thebestone Posted June 7, 2007 Author Share Posted June 7, 2007 That returns the URL of the page but still does not include the page anchor. Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/#findComment-270021 Share on other sites More sharing options...
thebestone Posted June 7, 2007 Author Share Posted June 7, 2007 So when I googled this, from what I've read it seems PHP can't get the page anchor bit. If I'm wrong, please let me know. I did find JS that does what I want but how would I get the output of the JS to be a variable in php? Is that possible? document.write(location.href); Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/#findComment-270089 Share on other sites More sharing options...
thebestone Posted June 7, 2007 Author Share Posted June 7, 2007 Does anyone have ideas for this? Thanks! Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/#findComment-270297 Share on other sites More sharing options...
thebestone Posted June 8, 2007 Author Share Posted June 8, 2007 One last bump Link to comment https://forums.phpfreaks.com/topic/54602-solved-referer/#findComment-270462 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.