สอบถามปัญหาเรื่องError Warning: Cannot modify header information - headers already sent by หน่อยครับแก้ยังไงครับ
คือมันขึ้น
Warning: Cannot modify header information - headers already sent by (output started at D:\AppServ\www\new\html\Code\insert_paymoney.php:2) in D:\AppServ\www\new\html\Code\insert_paymoney.php on line 24
แต่ข้อมูลก็ได้เข้าไปเก็บในฐานข้อมูลเรียบร้อยแล้ว
หน้า Insert_paymoney.php
<meta http-equiv="Content-Type" content="text/html; charset=windows-874">
<?
$dor=$_GET['dorder'];
$dpe=$_GET['porder'];
$dt=$_GET['tb'];
$txtid=$_GET['id'];
$txtref=$_GET['ref'];
$txtmon=$_GET['mon'];
$fname=$_POST['fname'];
$lname=$_POST['lname'];
$radiobutton=$_POST['radiobutton'];
$num_card=$_POST['num_card'];
$cw=$_POST['cw'];
$carlender=$_POST['carlender'];
$name_bank=$_POST['name_bank'];
include ("connect.php");
$sql1 = "INSERT INTO pay_money VALUES('$fname','$lname', '$radiobutton', '$num_card','$cw','$carlender','$name_bank','$txtref','$txtmon')";
$result1 = mysql_query($sql1);
$sql2="update order_table set pay_status='OK' where date_order='$dorder' and Tid='$tb'";
$result2=mysql_query($sql2);
header("location: ../code/pay_money.php?dorder=$dor&porder=$dpe&tb=$tb");
mysql_close($conn);
?>