Click to See Complete Forum and Search --> : Warning: Cannot send session cache limiter *RESOLVED*
flame_211
Oct 11th, 2002, 11:43 PM
Warning: Cannot send session cache limiter - headers already sent (output started at /home/alltom/public_html/flame/template.inc.php:1) in /home/alltom/public_html/flame/lib.inc.php on line 550
Whats wrong with that? I mean why am i getting it??
Line 547 to 550 in lib.inc.php:
session_set_save_handler('sess_open', '', 'sess_read', 'sess_write', 'sess_destroy', 'sess_gc');
session_name('s');
session_name('s');
session_start();
Im having problems with session_start() through out the site, any help???
Kings
Oct 12th, 2002, 11:11 AM
I think it means you've already sent some content to the browser. You'd have to do the session stuff first, then send the content.
flame_211
Oct 12th, 2002, 03:16 PM
thanks ill check it out
The Hobo
Oct 12th, 2002, 03:41 PM
you might also want to check out current PHP programming conventions. like those on how to properly do sessions these days.
flame_211
Oct 12th, 2002, 03:44 PM
ok in response to kings first:
I put all my session stuff first:
session_set_save_handler('sess_open', '', 'sess_read', 'sess_write', 'sess_destroy', 'sess_gc');
session_name('s');
session_name('s');
session_start();
then all my other stuff,
And I got this:
Fatal error: Failed to initialize session module in /home/alltom/public_html/flame/users.php on line 6
Warning: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0
Response to The Hobo:
I think i got the most up-to-date functions for my version of php if thats what you mean...
The Hobo
Oct 12th, 2002, 03:46 PM
What version are you using?
This sounds like a PHP problem to me, not a code probably. Either something isn't setup properly somewhere (php.ini or something), or something isn't installed properly.
I'll also admit I have no idea what session_set_save_handler() does.
flame_211
Oct 12th, 2002, 03:53 PM
Version: PHP 4.2.1
And im trying to contact the guy thats hosting me to get the session.save_path changed( i think thats the problem but im not sure ):confused:
The Hobo
Oct 12th, 2002, 04:48 PM
Yeah, with php 4.2, you specify a session like $_SESSION['a']; I think. Instead of session_name('s');
It's not going to help you out, though.
flame_211
Oct 12th, 2002, 05:07 PM
k, well, im gonna have my buddy look it over and figure it out :P
phpman
Oct 15th, 2002, 02:25 PM
why are you trying to serialize and save the session?
you don't need session_set_save_handler()
you very first line has to be session_start() before any other code.
and why do you have session_name twice? you don't even need that.
if you are on 4.2 then you must use $_SESSION[] the super global, unless you have globals turned on and for what reason I have no idea. by default it is turned off.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.