[FX.php List] Re: $_GET won't GIT

Andrew Denman adenman at tmea.org
Fri Jan 18 10:05:56 MST 2008


You could also check for the POST first and then not check for the GET, as
long as you'll never use the GET data if you're POSTing (code below).
Specifying the page action is a good fast fix though.

If($_POST){do post things}
Elseif($_GET){do get things}
Else{default action}

Andrew Denman

-----Original Message-----
From: fx.php_list-bounces at mail.iviking.org
[mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of John Moed
Sent: Friday, January 18, 2008 10:05 AM
To: fx.php_list at mail.iviking.org
Subject: [FX.php List] Re: $_GET won't GIT 

Jonathan,

I believe that it you leave the action="" blank (instead of
action="page.php"), it is the same as page=self. If you leave the action
blank, it's going to go to the page that is open. If you have get parameters
in the URL, it is going to re-use them...

If you have a page that can receive both Get and Post variables, you will
need to tell the page what to do if the Get or Post variables aren't set.

If (!isset($_post['postvalue']) {
Do nothing
}else{
Perform action
}

If (!isset($_get['getvalue']) {
Do nothing
}else{
Perform other action
}

Thanks,
John


_______________________________________________
FX.php_List mailing list
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list



More information about the FX.php_List mailing list