Jump to content

[SOLVED] why won't the php go into my page without erroring?


blyz

Recommended Posts

WHen i try to put the php loginbox on my page is messes my page up and doesn't work.

the code i put in is inbetween LOGIN START and LOGIN END thanks.

 

here is the code:

 

 

 

 

 

 

 

 

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>

<head>

 

 

  <title>.:: Software God - Unlimited Software and Serial Codes</title>

  <style>

body {background-color: #000;}

td {font-size: 10px; font-family: Verdana, Tahoma; color: #bbbbbb;}

td.nav {padding-left: 4px;}

a {font-size: 10px; font-family: Verdana, Tahoma; color: #775555; text-decoration:none;}

a:hover {font-size: 10px; font-family: Verdana, Tahoma; color: #775555; text-decoration:underline;}

.navhead {display: block; background-color:#222222; border: 1px dotted #555555; text-align:center; font-weight: bold;}

  </style>

  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

</head>

 

<body leftmargin="0" topmargin="0" marginheight="0" marginwidth="0">

 

<center>

<table id="Table_01" background="images/overall_bg.gif" border="0" cellpadding="0" cellspacing="0" width="739">

 

<tbody>

    <tr>

 

<td colspan="7">

<img src="images/index_01.gif" alt="" height="10" width="739"></td>

 

</tr>

 

<tr>

 

<td colspan="7">

<img src="images/index_02.gif" alt="" height="7" width="739"></td>

 

</tr>

 

<tr>

 

<td colspan="7">

<img src="images/index_03.gif" alt="" height="187" width="739"></td>

 

</tr>

 

<tr>

 

<td colspan="4">

<img src="images/index_04.gif" alt="" height="70" width="173"></td>

 

<td colspan="3">

<img src="images/index_05.gif" alt="" height="70" width="566"></td>

 

</tr>

 

<tr>

 

<td>

<img src="images/index_06.gif" alt="" height="31" width="5"></td>

 

<td class="nav" background="images/nav.gif" height="31" valign="top" width="163">

<!-- Navigation Starts Here -->

 

      <div class="navhead">Navigation</div>

 

» <a href="/index.html">Home</a><br>

 

» <a href="/join.html">Join</a><br>

 

» <a href="/faq.html">FAQ</a><br>

 

» <a href="/forums.php">Forums</a><br>

 

                        » <a href="/feedback.html">Feedback</a>

      <p>

</p>

      <div class="navhead">Members Area</div>

 

» <a href="#">Software</a><br>

 

» <a href="#">Serials</a><br>

 

» <a href="#">Forums</a><br>

 

» <a href="#">Report Broken Link</a>

      <p>

</p>

      <div class="navhead">Login</div>

 

» <a href="#">Link Here</a><br>

 

» <a href="#">Link Here</a><br>

 

» <a href="#">Link Here</a><br>

 

» <a href="#">Link Here</a><br>

 

<!-- NAvigation End -->

</td>

 

<td colspan="3">

<img src="images/index_08.gif" alt="" height="31" width="11"></td>

 

<td background="images/content.gif" valign="top" width="556">

<span style="font-weight: bold;">         LOGIN START<br>

   

 

 

<?

 

include("include/session.php");

?>

 

<html>

 

<body>

 

<table>

<tr><td>

 

 

<?

 

 

if($session->logged_in){

  echo "<h1>Logged In</h1>";

 

  echo "Welcome <b>$session->username</b>, you are logged in. <br><br>"

      ."[<a href=\"userinfo.php?user=$session->username\">My Account</a>]   "

      ."[<a href=\"useredit.php\">Edit Account</a>]   ";

 

  if($session->isAdmin()){

      echo "[<a href=\"admin/admin.php\">Admin Center</a>]   ";

  }

  echo "[<a href=\"process.php\">Logout</a>]";

}

else{

?>

 

<h1>Login</h1>

<?

 

if($form->num_errors > 0){

  echo "<font size=\"2\" color=\"#ff0000\">".$form->num_errors." error(s) found</font>";

}

?>

<form action="process.php" method="POST">

<table align="left" border="0" cellspacing="0" cellpadding="3">

<tr><td>Username:</td><td><input type="text" name="user" maxlength="30" value="<? echo $form->value("user"); ?>"></td><td><? echo $form->error("user"); ?></td></tr>

<tr><td>Password:</td><td><input type="password" name="pass" maxlength="30" value="<? echo $form->value("pass"); ?>"></td><td><? echo $form->error("pass"); ?></td></tr>

<tr><td colspan="2" align="left"><input type="checkbox" name="remember" <? if($form->value("remember") != ""){ echo "checked"; } ?>>

<font size="2">Remember me next time     

<input type="hidden" name="sublogin" value="1">

<input type="submit" value="Login"></td></tr>

<tr><td colspan="2" align="left"><br><font size="2">[<a href="forgotpass.php">Forgot Password?</a>]</font></td><td align="right"></td></tr>

<tr><td colspan="2" align="left"><br>Not registered? <a href="register.php">Sign-Up!</a></td></tr>

</table>

</form>

 

<?

}

 

 

echo "</td></tr><tr><td align=\"center\"><br><br>";

echo "<b>Member Total:</b> ".$database->getNumMembers()."<br>";

echo "There are $database->num_active_users registered members and ";

echo "$database->num_active_guests guests viewing the site.<br><br>";

 

include("include/view_active.php");

 

?>

 

 

</td></tr>

</table>

 

 

</body>

</html>

 

 

 

 

 

 

 

 

     

LOGIN END</span>

      <p>

  </p>

 

 

</td>

 

<td>

<img src="images/index_10.gif" alt="" height="31" width="4"></td>

 

</tr>

 

 

 

<tr>

 

<td>

<img src="images/index_13.gif" alt="" height="76" width="5"></td>

 

<td>

<img src="images/index_14.gif" alt="" height="76" width="163"></td>

 

<td>

<img src="images/index_15.gif" alt="" height="76" width="1"></td>

 

<td colspan="2">

<img src="images/index_16.gif" alt="" height="76" width="10"></td>

 

<td>

<img src="images/index_17.gif" alt="" border="0" height="76" width="556"></td>

 

<td>

<img src="images/index_18.gif" alt="" height="76" width="4"></td>

 

</tr>

 

 

<tr>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="5"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="163"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="1"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="4"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="6"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="556"></td>

 

<td>

<img src="images/spacer.gif" alt="" height="1" width="4"></td>

 

</tr>

 

  </tbody>

</table>

 

</center>

 

 

<div style="font-size: 0.8em; text-align: center; margin-top: 1em; margin-bottom: 1em;">

 

</div>

 

</body>

</html>

 

 

i get this error

 

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/blyz07/public_html/login.php:16) in /home/blyz07/public_html/include/session.php on line 46

 

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/blyz07/public_html/login.php:16) in /home/blyz07/public_html/include/session.php on line 46

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.