Session Problem


#1

Warning: Cannot modify header information - headers already sent by (output started at /home/.kokomo/thehuzzah/thehuzzah.com/templates/reg/top.htm:4) in /home/.kokomo/thehuzzah/thehuzzah.com/includes/members.php on line 353

When I hosted my website myself I had no such errors. Is it something DreamHost is adding to my website? Like a “session” type of code? Thanks in advanced.


#2

You might try the programming forum.

Wholly


#3

That means that text is being sent to the browser before some instance of the header() function is called. If you cannot find it yourself, post the PHP code here so that we can see.


Simon Jessey | Keystone Websites
Save $97 on yearly plans with promo code [color=#CC0000]SCJESSEY97[/color]


#4

Here is the code surrounding line 353:

if ($password == $pass) {

session_start();

session_register(‘username’);

session_register(‘scroller’);

session_register(‘template’);

session_register(‘email’);

session_register(‘exp’);

session_register(‘level’);

session_register(‘font’);

session_register(‘last_time’);

if ($level == 1) { $levelmd5 = “secretauthorizationnumber”; }

elseif ($level == 2) { $levelmd5 = “secretauthorizationnumber”; }

elseif ($level == 3) { $levelmd5 = “secretauthorizationnumber”; }

elseif ($level == 4) { $levelmd5 = “secretauthorizationnumber”; }

353 setcookie(‘veri’, $levelmd5);


#5

session_start(); should be on line 2 of your document, right after the very first opening “<?php” tag. Also, you are using a deprecated syntax for sessions [view updated syntax]. I suspect you are also relying on register_globals, which is no longer an option.


Simon Jessey | Keystone Websites
Save $97 on yearly plans with promo code [color=#CC0000]SCJESSEY97[/color]


#6

replace “/home/.kokomo/thehuzzah/thehuzzah.com” by “/home/thehuzzah/thehuzzah.com”

no need for the datablog


BUGabundo :o)
(``-_-´´)
http://BrinKadeiraS.BUGabundo.net
at http://www.dreamhost.com/r.cgi?249195
50$ discount with promo code “BUG50” on ALL plans