Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > Beginning PHP
Beginning PHP Beginning-level PHP discussions. More advanced coders should post to the Pro PHP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning PHP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old April 16th, 2005, 05:10 AM
Registered User
Join Date: Apr 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Help With PHP Headers!!

Hey guys, I have a really weird situation, I have read all of the other posts and it seems to be that they only help with local php hosting on your computer, but on my Hosting Provider, these warnings come up :

Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /home/dbzpride/public_html/main.php:5) in /home/dbzpride/public_html/include/session.php on line 39

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/dbzpride/public_html/main.php:5) in /home/dbzpride/public_html/include/session.php on line 39

On the line that it is reffering to on "session.php" (39) this is what is wrote :

37  function startSession(){
38  global $database;
39  session_start();

any help would be greatly appreciated!

Old April 17th, 2005, 04:16 AM
Authorized User
Join Date: Apr 2005
Posts: 28
Thanks: 0
Thanked 0 Times in 0 Posts

When calling session_start() you can not have any output to the client before it is called. This includes any whitespace as well.

Everything is temporary, some things are just more temporary than others... except for death, that seems to be pretty permanent

Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with PHP Headers JWinkler05 Beginning PHP 1 April 21st, 2008 12:23 PM
Hiding sub headers.... rupen Crystal Reports 6 May 14th, 2007 04:56 AM
WHat is "http headers"? gilgalbiblewheel Classic ASP Databases 1 September 14th, 2005 11:59 AM
Headers skicrud Beginning PHP 2 October 10th, 2003 02:21 PM
PHP install: CGI app misbehaved - no headers scalene Beginning PHP 2 July 14th, 2003 12:07 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.