If your server has register_globals turned off, you can't access a piece of form data with $name. Instead, you have to use either $REQUEST["name"], or $POST["name"] or $_GET["name"], depending on your request method.
Also, if you're trying to access the variable from within a function, and haven't globalized the variable, you won't be able to see it. Using $REQUEST["name"] will fix it in this case, too, as the $ variables are "superglobals".