Page 1 of 1

$go?

Posted: Wed Jul 24, 2002 9:01 am
by jackbk
Hi all,

I am rather new at PHP, and have a question, you experts probably can answer in no time... :D

I have this function that returns an <A HREF> for a number of items, like this:

Code: Select all

<a href="$PHP_SELF?go=**the action to take next**">Visible text</a>
I found a script somewhere doing something similar I want to do here, so that's where this snippit is coming from.

In my php script I have something like:

Code: Select all

if ($go == "**action 1**") &#123; 
  // Do the first action 
&#125; 
elseif ($go == "**action 2**") &#123;
  // Do the second action
&#125;
etc.

But now the problem: no matter what I try, the $go is never assigned... The <A HREF>'s look okay when I browse the page, but when I click the link nothing happens... It seems the parameters on the URL do not get parsed?

Here's is my config: Windows2000, PHP 4.2.1, Apache 1.3.22

Could someone point put the problem? Thanks in advance!

Jack

Posted: Wed Jul 24, 2002 9:03 am
by llimllib
click here

Posted: Wed Jul 24, 2002 9:08 am
by twigletmac
It's a sticky for a reason...

Mac

Posted: Wed Jul 24, 2002 9:15 am
by jackbk
Thanks for the quick respons... Sorry if this was a faq... I am not only new to PHP but also to this forum, and I have not read all "house rules" and faq documents yet...

Thanks again - with the details provided in the "Sticky", the problem seems to be fixed... :)

Regards,

Jack

Posted: Wed Jul 24, 2002 9:27 am
by llimllib
nah problem dude