jjmusicpro Posted August 7, 2008 Share Posted August 7, 2008 I get a bunch of errors that are ok, how do i turn these off in my php.ini ? Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/***************/httpdocs/themes/iCGstation/theme.php:85) in /usr/local/www/vhosts/************/httpdocs/includes/sessions.php on line 251 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/*****************/httpdocs/themes/iCGstation/theme.php:85) in /usr/local/www/vhosts/****************/httpdocs/includes/sessions.php on line 252 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/xxxxxxxxxxxx/httpdocs/themes/iCGstation/theme.php:85) in /usr/local/www/vhosts/xxxxxxxxxxxxxxxxxxx/httpdocs/modules/Forums/viewtopic.php on line 572 Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 Except those errors are not OK. o-O Your session is not being set. Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 Except those errors are not OK. o-O Your session is not being set. They seem to be getting set, because i can loginto the site and cruz around, post replies etc. Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 Well something is not working, so you should fix it before your site breaks one day. Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 Well something is not working, so you should fix it before your site breaks one day. why would it throw those errors? Quote Link to comment Share on other sites More sharing options...
wildteen88 Posted August 7, 2008 Share Posted August 7, 2008 That error suggests your are using the header() function to send HTTP headers to the server . header() can only be used before any output. From the error message you have posted, I can tell you that the output is on line 85 in themes/iCGstation/theme.php (this is the cause) however the error was triggered in includes/sessions.php on line 251. Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 looks like you may have a BOMB or whatever they call it binary bomb or something look for a space at the end of files included before redirect or files of where redirect happens or session starts or any file, spaces after the last bit of php or anything and comments do it too. to turn errors off you say error_reporting(0); ob_start may help u look into that but thats not a fix its a work around Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 looks like you may have a BOMB or whatever they call it binary bomb or something look for a space at the end of files included before redirect or files of where redirect happens or session starts or any file, spaces after the last bit of php or anything and comments do it too. to turn errors off you say error_reporting(0); ob_start may help u look into that but thats not a fix its a work around where do i do that at? the error part? this is on a phpnuke type site Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 You mean the BOM? It's the Byte Order Mark. =P And it would appear at the beginning of files, not randomly in the middle. Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 try and rember if you put a space acidently in some file at the beggining, thats all the whisdom i can givbe you now my child now you muct fend for yourself or pay me a small fee, lol joke, yeh as he said probs at teh beggingin Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 No, I meant that it couldn't be the BOM because the output was started on line 85 of theme.php. Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 so i check the file for a space or something what file? Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 if there are any includes before 85 then they can have the bom in them too Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 the only include i see is this include("themes/iCGstation/tables.php"); i looked in it, didnt see anything and now i get this error Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/**************/httpdocs/themes/iCGstation/theme.php:52) in /usr/local/www/vhosts/**************/httpdocs/includes/sessions.php on line 251 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/**************/httpdocs/themes/iCGstation/theme.php:52) in /usr/local/www/vhosts/**************/httpdocs/includes/sessions.php on line 252 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/**************/httpdocs/themes/iCGstation/theme.php:52) in /usr/local/www/vhosts/**************/httpdocs/includes/page_header.php on line 494 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/**************/httpdocs/themes/iCGstation/theme.php:52) in /usr/local/www/vhosts/**************/httpdocs/includes/page_header.php on line 500 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/www/vhosts/**************/httpdocs/themes/iCGstation/theme.php:52) in /usr/local/www/vhosts/**************/httpdocs/includes/page_header.php on line 501 <?php $bgcolor1 = "#EAEAEA"; $bgcolor2 = "#EAEAEA"; $bgcolor3 = "#EAEAEA"; $bgcolor4 = "#EAEAEA"; $textcolor1 = "#000000"; $textcolor2 = "#000000"; include("themes/iCGstation/tables.php"); function themeheader() { global $admin, $user, $sitename, $slogan, $cookie, $prefix, $db, $nukeurl, $anonymous; $showbanners = ads(0); cookiedecode($user); $username = $cookie[1]; if ($username == "") { $username = "Anonymous"; } echo "<body bgcolor=\"#FFFFFF\" text=\"#000000\">"; if ($username == "Anonymous") { $theuser = " <a href=\"modules.php?name=Your_Account\">"._LOGIN."</a> or <a href=\"modules.php?name=Your_Account&op=new_user\">"._BREG."</a>"; } else { $theuser = " "._BWEL." $username!"; } $datetime = "<script type=\"text/javascript\">\n\n" ."<!-- // Array ofmonth Names\n" ."var monthNames = new Array( \""._JANUARY."\",\""._FEBRUARY."\",\""._MARCH."\",\""._APRIL."\",\""._MAY."\",\""._JUNE."\",\""._JULY."\",\""._AUGUST."\",\""._SEPTEMBER."\",\""._OCTOBER."\",\""._NOVEMBER."\",\""._DECEMBER."\");\n" ."var now = new Date();\n" ."thisYear = now.getYear();\n" ."if(thisYear < 1900) {thisYear += 1900}; // corrections if Y2K display problem\n" ."document.write(monthNames[now.getMonth()] + \" \" + now.getDate() + \", \" + thisYear);\n" ."// -->\n\n" ."</script>"; $public_msg = public_message(); $tmpl_file = "themes/iCGstation/header.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; blocks('left'); $tmpl_file = "themes/iCGstation/left_center.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; } function themefooter() { global $index, $foot1, $foot2, $foot3, $foot4, $copyright, $totaltime, $footer_message; if (defined('INDEX_FILE')) { $tmpl_file = "themes/iCGstation/center_right.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; blocks('right'); } echo" </td>" . " </tr>" . " </table>" . " <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\">" . " <tr> " . " <td align=\"right\"><a href=\"#top\"><img src=\"themes/iCGstation/forums/images/top.gif\" border=\"0\" /></a></td>" . " </tr>" . " </table>" . " <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\">" . " <tr> " . " <td><a href=\"http://www.nukemods.com\" target=\"_blank\"><img src=\"themes/iCGstation/forums/images/bt_left.gif\" border=\"0\" /></a></td>" . " <td width=\"100%\" class=\"indexbom\" align=\"center\">"; $footer_message = footmsg(); echo " </td>" . " <td><a href=\"http://www.ioptional.com\" target=\"_blank\"><img src=\"themes/iCGstation/forums/images/bt_right.gif\" border=\"0\" /></a></td>" . " </tr>" . " </table>" . " </td>" . " <td width=\"10\" nowrap=\"nowrap\" class=\"righttd\"></td>" . " </tr>" . "</table>" .""; } function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) { global $anonymous, $tipath; if ($notes != "") { $notes = "<br><br><b>"._NOTE."</b> <i>$notes</i>\n"; } else { $notes = ""; } if ("$aid" == "$informant") { $content = "$thetext$notes\n"; } else { if($informant != "") { $content = "<a href=\"modules.php?name=Your_Account&op=userinfo&username=$informant\">$informant</a> "; } else { $content = "$anonymous "; } $content .= ""._WRITES." <i>\"$thetext\"</i>$notes\n"; } $posted = ""._POSTEDBY." "; $posted .= get_author($aid); $posted .= " "._ON." $time ($counter "._READS.")"; $tmpl_file = "themes/iCGstation/story_home.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; } function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext) { global $admin, $sid, $tipath; $posted = ""._POSTEDON." $datetime "._BY." "; $posted .= get_author($aid); if ($notes != "") { $notes = "<br><br><b>"._NOTE."</b> <i>$notes</i>\n"; } else { $notes = ""; } if ("$aid" == "$informant") { $content = "$thetext$notes\n"; } else { if($informant != "") { $content = "<a href=\"modules.php?name=Your_Account&op=userinfo&username=$informant\">$informant</a> "; } else { $content = "$anonymous "; } $content .= ""._WRITES." <i>\"$thetext\"</i>$notes\n"; } $tmpl_file = "themes/iCGstation/story_page.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; } function themesidebox($title, $content) { $tmpl_file = "themes/iCGstation/blocks.html"; $thefile = implode("", file($tmpl_file)); $thefile = addslashes($thefile); $thefile = "\$r_file=\"".$thefile."\";"; eval($thefile); print $r_file; } ?> Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 you can have a BOM inserted automaticaly on some OS's where it says <?php **HERE** $bgcolor1 = "#EAEAEA"; so u need to backspace <?php$bgcolor1 = "#EAEAEA"; then a str8 return <?php $bgcolor1 = "#EAEAEA"; if none of this works, just put ob_start(); at the very begining of teh file after <?php Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 First of all, it's not the OS, it's the file editor. Secondly, it's not after the PHP tag, it's before anything in the file. Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 First of all, it's not the OS, it's the file editor. Secondly, it's not after the PHP tag, it's before anything in the file. im not sure because iv had this occur afte rthe <?php tag im not sure of the workings but iv had it occure <?php HERE $blah Quote Link to comment Share on other sites More sharing options...
jjmusicpro Posted August 7, 2008 Author Share Posted August 7, 2008 problem fixed. there was an option in the confrig file to turn warnings off and on, and i had it on, so i turned it off and bingo it works Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 7, 2008 Share Posted August 7, 2008 Okay, when your site breaks, don't yell if I say "I told you so."... >_> Quote Link to comment Share on other sites More sharing options...
nadeemshafi9 Posted August 7, 2008 Share Posted August 7, 2008 problem fixed. there was an option in the confrig file to turn warnings off and on, and i had it on, so i turned it off and bingo it works hey you could have done that yourself just for that page and that is the error you need to find it and fix it, dont think we were wrong and ur right, cos the error is there you just stopped displaying it, one day it will just stop working Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.