Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Dave Moore
December 20, 2005, 10:56 pm
rate this thread
Here's my problem. I'm having trouble managing the additional variables
on the end of my URL. For example, I might have a URL like the following:
It's the 'option' variables I'm having problems with. I would typically use
variables of this form to control various aspects of the current page.
However, the actual options present will be dependant on the current mode of
the page. Now lets say that I want to put a link on my page that adds a new
'option3' variable and reloads the page. The php might look like:
w link with new option</A>\n";
But I can't really use this because this page might not actually contain
option1 and option2 - it may have option5 and option6 instead. What I want
to be able to do is to leave the current options alone and just add the ones
I want to add. What is the best way of doing this?.
I reckon the best way to handle it would be to have a $_SERVER variable that
would give me the full current URL including all of the options. That way I
could a line similar to:
echo '<A HREF="'.$_SERVER['FULL_URL'].'?'.SID.'&option3=5'."\">new link with
and it would just work. Is there such a variable?, or is there a better way
of doing this?.
Ta in advance,