Hi everyone.
I'm developing a site (PHP + MySQL) in a terribly limited server. For reasons too long to explain, I need to read a user cookie and given some conditions, include cookie variable in the URL. That is:
1 - read cookie
2 - then rewrite URL to include this variable.
I don't even know if you can read a user's cookie using a .htaccess file, then use this value to rewrite the URL. Then there is the other problem: write the Rewriting rule.
And believe me, this has to be done this way, the URL must be rewritten before starting PHP execution. The server belongs to a public institution and all decisions are taken by bureaucrats. This is the only solution I can apply given the technical limitations and bureaucratic restrictions I've been imposed.
Please help.
Thank you.
I'm developing a site (PHP + MySQL) in a terribly limited server. For reasons too long to explain, I need to read a user cookie and given some conditions, include cookie variable in the URL. That is:
1 - read cookie
2 - then rewrite URL to include this variable.
I don't even know if you can read a user's cookie using a .htaccess file, then use this value to rewrite the URL. Then there is the other problem: write the Rewriting rule.
And believe me, this has to be done this way, the URL must be rewritten before starting PHP execution. The server belongs to a public institution and all decisions are taken by bureaucrats. This is the only solution I can apply given the technical limitations and bureaucratic restrictions I've been imposed.
Please help.
Thank you.