Posted by 1 on 12/09/05 05:40
I was wondering how I can do the following.
Example: When a surfer goes to index.php there is a list of links including
example.php. I only want the link to appear as example.php if a id variable
is given in the url. Example. www.mydomain.com/index.php?id=564, if not "ID"
is given, example www.mydomain.com/index.php or
www.mydomain.com/index.php?othervariable=5, I would like the example.php
link to go to example2.php instead of example.php.
Something like: $link = example, if no ID exists, $link=example2. In the
source the link will appear as www.mydomain.com/$link.php.
I am new to php and don't know how I would put this in proper code. Hope
someone can help.
[Back to original message]
|