Hello,
I was wondering how to test for an anchor in the URL and to get its value.
Most URLs look something like this:
showthread.php?t=10376481
But sometimes an anchor is appended to the URL:
showthread.php?t=10376481[B]#4242[/B]
The reason I am asking is because on my forum I want members to be able to send links to posts. To be able to do that, I need to send an anchor. However, the issue lies in that members may have different display settings so they'll be displaying a different number of posts per page than perhaps the person sending the link.
If the link sent is to the 21st post, but the person receiving it is displaying 20 posts per page, then it would be on the second page.
What I am looking to achieve is:
1) Test for an anchor's presence. If it's not there then don't worry about it.
2) If it's there, get its value and determine which post it is.
3) Once the post is determined, determine which page the post is on.
4) Once that is determined, direct the user there.
Unless there's a completely different (and easier) method of doing this.
Thank you for your time.