Jump to content

Recommended Posts

I want to be able to identify every page by a unique ID

 

I dont want to manually assign every page i have with a personal ID. Is there a way of giving each page a unique ID based on file location or something??

 

I thought the URL using HTTP_REFERRER, but when u have a GET variable, it seems to be empty...

 

Thanks in advance.

Link to comment
https://forums.phpfreaks.com/topic/185893-any-ideas/
Share on other sites

If he is using Post data to change the page display then the URL might be the same so md5 won't help.

 

There really is only way true way to do this IF and thats a big IF the pages have different URL's.  and that is define a constant for each page, like vbulletin.  But if the pages truley all have different URL's then hashing the URL is the perfect way to go, of course, capital letters might change that identifier so make sure you toLowerCase() before you md5()

Link to comment
https://forums.phpfreaks.com/topic/185893-any-ideas/#findComment-981631
Share on other sites

If he is using Post data to change the page display then the URL might be the same so md5 won't help.

 

There really is only way true way to do this IF and thats a big IF the pages have different URL's.  and that is define a constant for each page, like vbulletin.  But if the pages truley all have different URL's then hashing the URL is the perfect way to go, of course, capital letters might change that identifier so make sure you toLowerCase() before you md5()

 

Thanks, I will do that. As long as I understand what you mean by pages having different urls.

 

They are all their own filenames in say a single folder. Good enough??

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/185893-any-ideas/#findComment-981637
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.