Hér sendi ég kóðann getiði sagt mér hvað er vitlaust?
(html)
(head)
(meta http-equiv=“Content-Language” content=“is”)
(title)Skráning(/title)
(/head)
(body text=“#00FF00” bgcolor=“#FF0000”)
(form method=“POST” action=“_private/skra.php”)
Þitt e-mail:(/p)
(p style=“margin-top: 0; margin-bottom: 0”)
(input type=“text” name=“email” size=“20”)(/p)
(p style=“margin-top: 0; margin-bottom: 0”) (/p)
(p style=“margin-top: 0; margin-bottom: 0”)Notendanafn sem þú vilt:(/p)
(p style=“margin-top: 0; margin-bottom: 0”)
(input type=“text” name=“nafn” size=“20”)(/p)
(p style=“margin-top: 0; margin-bottom: 0”) (/p)
(p style=“margin-top: 0; margin-bottom: 0”)Lykilorð sem þú vilt:(/p)
(p style=“margin-top: 0; margin-bottom: 0”)
(input type=“password” name=“pass” size=“20”)(/p)
(p style=“margin-top: 0; margin-bottom: 0”) (/p)
(p style=“margin-top: 0; margin-bottom: 0”)
(input type=“submit” value=“Staðfesta” name=“B1”)(/p)
(/form)
(/body)
(/html)
og hér er skra.php:
(html)
(head)
(meta http-equiv=“Content-Language” content=“is”)
(title)Skráning(/title)
(/head)
(body text=“#00FF00” bgcolor=“#FF0000”)
(?
$efni = “nafn:”;
$efni .= $_POST['nafn'];
$efni .= “lykilorð:”;
$efni .= $_POST['pass'];
$to = “allihj@hotmail.com”;
$headers = “From: My site\\nReply-To: ”;
$headers .= $_POST['email'];
$headers .= “\\n”;
if(mail($to,“Skráning”,$efni,$header)){
?)
(p)(b)(font face=“Comic Sans MS” size=“5”)Þú færð e-mail fljótlega ef skráning tókst.(/font)(/b)(/p)
(?}else{?)
(p)(b)(font face=“Comic Sans MS” size=“5”)Skráning mistókst.(/font)(/b)(/p)
(?}?)
(/body)
(/html)