Allie Albatross
Junior Member
- Jan 31, 2009
- 116
- 44
If I was writing a reply to a Craigslist advertisement, I would say something along the lines of "Hello [Username], thank you for contacting me". Now, I want [Username], to be based off of whatever I type in the URL. Here is what I have so far.
Then wherever I want it to be included, I just write "Hello <?php echo $name; ?>, thank you for contacting me". Now, it works fine, but only when I actually define a name. If I don't, it throws up this error.
Code:
<?php
$name = $_GET['name'];
$time = $_GET['time'];
?>
I really don't know what I'm doing, it took long enough to even find what I was looking for, as I have no idea what the terminology would be. Would anyone be kind enough to help? Also, I structure my URL this way, I assume it's the correct form.Notice: Undefined index: time in C:\WAMP\www\xxx\index.php on line 7
Now, that's in clear plain view, how might I obfuscate the URL? I suppose encoding the URL is my only option.
It doesn't really hide anything, just makes it more difficult to read. Any suggestions?Encoded: http%3A%2F%2Fwww.domain.com%2Findex.php%3Fname%3DAllie_Albatross
Last edited: