Hi !Me and my problems again!
I found this PHP script on the net....and I found it is incorrect?!
-when i load form.html i get simple form result with " ;?> in front of it!!!...than i tried to renama form.html to form.php and I got result with simple form but now the first line in my browser says: Notice: Undefined variable: HTTP_REFERER in C:\WEB SERVER\wwwroot\test\form.php on line 6 !!Damn! Help me please...what to do....
[/B]
Files:
form.html
<html>
<head><title>Send a link</title></head>
<body bgcolor="#ffffff">
<form action="refer.php" method="post">
<?php $fullurl = "{$HTTP_REFERER}";
echo "$fullurl<br> " ;
echo"<input type=hidden name=link value=$fullurl>" ;?>
Friend E-mail: <input type="text" name="email"><br>
Friend Name: <input type="text" name="name"><br>
Your Name: <input type="text" name="sendername"><br>
Your E-mail: <input type="text" name="senderemail"><br>
<input type="submit" value="Go!"> <input type="reset" value="reset">
</form>
</body>
</html>
refer.php
<?
mail("$email", "Your website","Hi $name !, $sendername at $senderemail wanted you to read this article at $link.", "from: $mailheaders\"$sendername\" $senderemail\n");
echo "<div align=\"center\"><table width=\"96%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" ";
echo "style=\"font-size:11pt;font-color:black;\">";
echo "<tr height=\"40\" align=center><td><p> </p></td></tr>";
echo "<tr><td >An e-mail with the link was sent to <font color=#ED1820 >$name</font> at <a href=\"mailto:$email\">$email</a> from <font color=#ED1820 >$sendername</font> at <a href=\"mailto:$senderemail\">$senderemail</a>, now also <font color=#ED1820 >$name</font> your friend ";
echo " will know about the link <a href=$link target=_blank>$link </a></td></tr>";
echo "</table></div>";
?>
I belive this problem isn't to big😉
Klemen