This line isn't working for me:
header("location:landing.php?id=md5($_REQUEST['user'])");
I need to pass the id variable. How do I do this?
Only variable can be parsed into double-quote (ex.: "$id"). Code need to be evaluate first and then you append the result to your string.
header('Location: landing.php?id=' . md5($_REQUEST['user']));
There was also a typo in the way you wrote the header, HTTP header name should starts with a capital letter and there is a space after the ":". I'm not 100% sure it needs to be exactly this way, but it's the standard way to do it.
!
Note: HTTP/1.1 requires an absolute URI as argument to » Location: including the scheme, hostname and absolute path, but some clients accept relative URIs. You can usually use $_SERVER['HTTP_HOST'], $_SERVER['PHP_SELF'] and dirname() to make an absolute URI from a relative one yourself: