please i have a problem with my login page when i hosted my website it is showing me this error please help me
here are the errors that it show:-

  1. Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/coezelib/public_html/checkstaffLogin.php:10) in /home/coezelib/public_html/checkstaffLogin.php on line 13

  2. Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/coezelib/public_html/checkstaffLogin.php:10) in /home/coezelib/public_html/checkstaffLogin.php on line 13

  3. Warning: Cannot modify header information - headers already sent by (output started at /home/coezelib/public_html/checkstaffLogin.php:10) in /home/coezelib/public_html/checkstaffLogin.php on line 35

Recommended Answers

All 3 Replies

You have probably sent some HTML output before session_start() line in your code. Make sure that the session_start() function is on the very beginning of the script. Also make sure there is no space that you are unaware of in the beginning before the <?php ?> block. If there are included files before session_start() they also should not sent HTML output.

You can post your script (or part of it) here for us to see what is the problem.

show us your code... its too hard to tell what line 13 is...

try placiing ob_start(); after your session_start();

This will allow you to render code and send headers without getting the error.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.