ผมจะรหัสผ่านเข้าเมล์ครับแต่มันบอกว่า
"Warning: mail() [function.mail]: "sendmail_from" not set in php.ini or custom "From:" header missing in C:\AppServ\www\math\3\sendpassword.php on line 28"
นี่คือ code
<?
$user_forget=$_POST['forget'];
if($user_forget==""){
echo"<B>กรุณากรอกข้อมูลให้ครบ";
echo"<hr><a href= forget.php>อีกครั้ง</hr>";
exit;
}
$dbhost="localhost";
$dbuser="root";
$dbpass="1234";
$dbname="math";
mysql_connect($dbhost,$dbuser,$dbpass) or die(" connect ไม่ได้");
mysql_select_db($dbname);
$sql="SELECT * from member where username='$user_forget'";
$result=mysql_db_query($dbname,$sql);
$num=mysql_num_rows($result);
$record=mysql_fetch_array($result);
$to=$record[email];
$pass=$record[password];