سلام
یه سوال درباره فرم ها داشتم
این دو تا رو ببینید
بهم بگین درسته؟
چیکار کنم؟
[HTML]<fieldset>
<form action="send3.php" method="get" name="us" >
نام و نام خانوادگی: <input name="1" type="text" size="30"><br>
آدرس ایمیل: <input name="2" type="text" size="30"><br>
متن مورد نظر: <br>
&n bsp; <textarea name="3" cols="40" rows="10" ></textarea><br>
<input value="ارسال" type="submit" name="s"><input type="reset" value="پاک کردن">
</fieldset></form>[/HTML]
اسمش send3.php
[PHP]<?php
function htmlspecialchars_uni($message)
{
$message = preg_replace("#&(?!\#[0-9]+;)#si", "&", $message);
$message = str_replace("<","<",$message);
$message = str_replace(">",">",$message);
$message = str_replace("\"",""",$message);
return $message;
}
if($_REQUEST['s'])
{
$name = htmlspecialchars_uni($_POST['1']);
$name = htmlspecialchars_uni($_POST['1']);
$name = htmlspecialchars_uni($_POST['3']);
$to = "youremail@gmail.com";
$subject = "?????";
$body = "???: $name";
$from = "email@domain.com";
$headers = "From: $from\r\n";
mail($to, $subject, $body, $headers);
}
?>[/PHP]