0

I used another host before and the code worked... But now it won't work in the new one? What doesen't let that to read the header?

if(isset($_REQUEST['u_submit'])){
  extract($_REQUEST);
  $u_title = htmlentities($_REQUEST['u_title'], ENT_QUOTES);
  $u_description = htmlentities($_REQUEST['u_description'], ENT_QUOTES);
  $u_des2 = mysql_real_escape_string($_REQUEST['u_des2']);
  mysql_query("UPDATE funn SET category='$u_category', ac1='$u_ac1', ac2='po', ac3='po', lchanged='$name', imglink='$u_imglink', title='$u_title', description='$u_description', des2='$u_des2', published='$u_published' WHERE id='$u_id'") or die("Your data cannot update".mysql_error());
   echo "<a href='home.php'><span style='color: green; font-weight: 900;'><img src='img/done.png' valign='middle' height='35' width='auto' style='margin-left: 35px;'> Ndryshimet u ruajtën me sukses!</span></a>";
   header('Location: home.php');
   exit;
}

The server reads this perfectly:

echo "<a href='home.php'><span style='color: green; font-weight: 900;'><img src='img/done.png' valign='middle' height='35' width='auto' style='margin-left: 35px;'> Ndryshimet u ruajtën me sukses!</span></a>";

But this not? Why?

header('Location: home.php');

And also it read's this? Wtf?

exit;

How can the server skip the header? It is in the middle of echo and exit??? Im really confuzed, please help me out... Thanks :(

Flamur Beqiraj
  • 1,957
  • 2
  • 13
  • 18

0 Answers0