Welcome to PHP. This isn't difficult at all - very easy in fact 8)
Whenever you need to read in variables to PHP from the URL you use this:
You may also notice both (int) and (string) ?
# sample URL -> [url=http://www.mydomain.com?id=10&action=ViewUsers]www.mydomain.com?id=10&action=ViewUsers[/url]
$Id = (int) $_GET['id'];
$Action= (string) $_GET['action'];
# rest of PHP script
These placed in front of a variable will check that the data is of the correct type before assigning $Id and $Action the contents of $_GET.
For future reference you'll also see a lot about $_POST ?
This is the same as $_GET but instead of variables passed by the URL, they're passed via a FORM when it's method = 'post'.
Your going to dig PHP ain't you ? LoL