Jump to content

Quick Question [SOLVED]


SLG

Recommended Posts

Hey all,

I am a bit noob to PHP/MySQL (I just started a few weeks ago). Anyway, I am a webmaster for the site AlbinoShades, and I am about to release the new version of the site soon. This new site has a login feature that was a serious pain in the ass to get working. Well I finnaly got everything up and running, and started intergrating the script into the site, then this ugly error appeared at the top saying:
[code]Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/albinosh/public_html/rc2/home.php:5) in /home/albinosh/public_html/rc2/include/session.php on line 47[/code]

But then everything else worked, I could login, password protect pages, edit admin settings etc. So I looked at line 47 in sessions.php and saw this line:
[code]start_session()[/code]
I knew that editing this would screw up the script, but I couldnt resist, I commented that line, then the ugly error went away, but I couldn't login. So I un-commented that line, and same thing happens. Any ideas why this error message is showing?
Link to comment
Share on other sites

You want to make sure that therer are no blank lines before "session_start()" and that is the first thing on the page. Also...

[code]<?php

  session_start();
   
  ob_start();

?>[/code]

Sometimes adding the ob_start() function can address [i]other[/i] header related issues.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.