solidariti
12-07-2005, 05:19 AM
Hi I have tried seraching for this but couldnt find anything.
Here are the errors when I ran the site:
Warning: Cannot modify header information - headers already sent by (output started at /berw/ugrad1/base/j/jra3/public_html/organiser/conn.php:13) in /berw/ugrad1/base/j/jra3/public_html/organiser/index.php on line 23
Warning: Cannot modify header information - headers already sent by (output started at /berw/ugrad1/base/j/jra3/public_html/organiser/conn.php:13) in /berw/ugrad1/base/j/jra3/public_html/organiser/index.php on line 27
Heres the code that is producing it, any ideas what to do? Why this is causing it?:
<?php
require("conn.php");
if ($_POST['btnLogin'] != "") {
//check the username and password
$user = $_POST['userEmail'];
$pass = $_POST['userPassword'];
$result = mysql_query("SELECT * FROM tblUsers WHERE userEmail = '" . $user . "' AND userPassword = '" . $pass . "'");
if (mysql_num_rows($result) != 0) {
//if they match we are logged in
$row = mysql_fetch_array($result);
setcookie ("organiser", $row['userGUID'],time()+31449600, "/");
header("Location:organiser.php");
}else{
$nologin = true;
}
}
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
Here are the errors when I ran the site:
Warning: Cannot modify header information - headers already sent by (output started at /berw/ugrad1/base/j/jra3/public_html/organiser/conn.php:13) in /berw/ugrad1/base/j/jra3/public_html/organiser/index.php on line 23
Warning: Cannot modify header information - headers already sent by (output started at /berw/ugrad1/base/j/jra3/public_html/organiser/conn.php:13) in /berw/ugrad1/base/j/jra3/public_html/organiser/index.php on line 27
Heres the code that is producing it, any ideas what to do? Why this is causing it?:
<?php
require("conn.php");
if ($_POST['btnLogin'] != "") {
//check the username and password
$user = $_POST['userEmail'];
$pass = $_POST['userPassword'];
$result = mysql_query("SELECT * FROM tblUsers WHERE userEmail = '" . $user . "' AND userPassword = '" . $pass . "'");
if (mysql_num_rows($result) != 0) {
//if they match we are logged in
$row = mysql_fetch_array($result);
setcookie ("organiser", $row['userGUID'],time()+31449600, "/");
header("Location:organiser.php");
}else{
$nologin = true;
}
}
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>