ok here is my problem. i have a website i created on godaddy.com. i have a survey form with questions. i initially wanted the answers emailed to me but godaddy has the mail() function disabled. i was then forced to insert the answers into a database provided. i created a login system where i can login, create new users and display the results of the survey. i created this on my computer. i am running apache 2 , PHP 4.31 and mysql 4.0.4. the entire app works fine on my server but whne i upload it and log in i get a white page. the only info i changed in my scripts before upload was the server info and database info. my first script is below
<?php
//check for required fields from the form
if ((!$HTTP_POST_VARS[username]) || (!$HTTP_POST_VARS[password])) {
header("Location:log_in.php");
exit;
}
//create session id
$sessionid=$HTTP_POST_VARS[username];
//connect to server and select database
$conn = mysql_connect("servername", "username", "password") or die(mysql_error());
mysql_select_db("database",$conn) or die(mysql_error());
//create and issue the query
$sql = "select username from users where username = '$HTTP_POST_VARS[username]' AND password=('$HTTP_POST_VARS[password]')";
$result = mysql_query($sql,$conn) or die(mysql_error());
//get the number of rows in the result set; should be 1 if a match
if (mysql_num_rows($result) == 1) {
//start session if logged in
session_start();
$HTTP_SESSION_VARS['auth_user']= $sessionid;
header("Location:menu.php");
}
else
{
//display message if not authorized
echo "You Are Not Authorized";
exit;
}
?>
it is fairly simple and straight forward. when you log in the form posts to this script. i know it is interacting with the db because if i put in the wrong username or password i get the not aauthorized message. i have ried taking out all the session info out and it still won't work. i think maybe they have something i need disabled. if anyone is interested here is a link to there phpinfo()
http://ftphelp.secureserver.net/linux-phpinfo.html
if someone has an idea of whats wrong i would sure appreciate the help.
thanks in advance