Let's say the address is: /page.php And in page.php there's this code:
if ($_GET['action'] == "browse"){...
Then it gives me an error which states that $action couldn't be found. How do I check if $action exists?
if(isset($GET['action']) && $GET['action'] == browse) {
}
or use the [man]array_key_exists[/man] function
array_key_exists("action", $_GET)
I'm doing this:
if (isset($_GET['action'])){ ... } else { ... }
And it gives me this error: Notice: Undefined index: action in C:\BigApache\Apache\htdocs\emblem\submissions.php on line 64
Nevermind, the second one (array_key_exists("action", $_GET)) works.