PHP headers already sent problem

Lukizzles

New Member
Hello there when i go to the site it says \[code\]Warning: session_register() [function.session-register]: Cannot send session cache limiter - headers already sent (output started at /home/content/49/5712349/html/c/admin/admin.php:17) in /home/content/49/5712349/html/c/admin/admin.php on line 39Warning: Cannot modify header information - headers already sent by (output started at /home/content/49/5712349/html/c/admin/admin.php:17) in /home/content/49/5712349/html/c/admin/admin.php on line 41\[/code\]I saw other questions and none answered me.Here is the code thanks alot.\[code\]<?php if (isset($_SESSION['mattyc-admin'])){ header ('Location: admin/home.php');}if (!isset($_GET['me'])){ header ('Location: http://www.stat-me.com/mattyc');}if ($_GET['me'] != 'mattyc'){ header ('Location: http://www.stat-me.com/mattyc');}?><?phpif ($_POST['name'] != "" && $_POST['password'] !="") {//require "../../scripts/connect_to_mysql.php";$name = $_POST['name'];$pass = $_POST['password'];$name = strip_tags($name);$pass = strip_tags($pass);//$name = mysql_real_escape_string($name);//$pass = mysql_real_escape_string($pass);$name = eregi_replace("`", "", $name);$pass = eregi_replace("`", "", $pass);//$pass = md5($pass);if ($name == 'mattyc' && $pass == 'qwerty'){ if (isset ($_SESSION['mattyc-admin'])){ header ('Location: admin/upload.php'); }else{ session_register('mattyc-admin'); $_SESSION['mattyc-admin'] = ('mattyc-adminp'); header ('Location: admin/upload.php'); }}}?>\[/code\]
 
Back
Top