Jump to content

stumped... php error when uploaded


amavadia

Recommended Posts

Hi all

 

So ive been designing implementing my php website for the past few months locally using WAMP stack, and coding with php designer.

 

All was fine, and the site worked perfectly with a mysql database.

 

I then uploaded it to my webserver with support for php and mysql, built the tables as required, and the site does work, but I am gettin this error on some pages.:

 

Warning: Cannot modify header information - headers already sent by (output started at /home/sites/findaplacement.com/public_html/list.inc.php:57) in /home/sites/findaplacement.com/public_html/update_customer_admin.php  on line 90

 

This occurs on pages where i used validation to check the input of forms, then submit the details to the database to be stored. I have an IF loop that says if everything is OK, then update the record in the database, and then using

header('Refresh: 5; URL=account.php');

on line 90 of the page update_customer_admin.php send the user to their account home page.

 

I have made sure that the header is the first output the page gives, and the file it is showing as the problem (list.inc.php) is a simple include file which contains the definition of a few arrays, nothing else. And line 57 dosent event have any code on it, its just the php closing tag '?>'

 

I find it strange because it works perfectly locally.

 

Anyone have any idea what might be different on my webserver which might cause this??

 

Thanks

 

Link to comment
Share on other sites

line 57 doesn't event have any code on it, its just the php closing tag '?>'

 

You probably have some white-space on that line after the ?> tag.

 

AMAZING... Thank You!!

 

Really would not have thought about that... all that aggravation for a space!

Link to comment
Share on other sites

You php.ini must have the output_buffering setting turned ON or set to a specific value, thereby hiding the problem. I would recommend turning output_buffing OFF because that will result in a development system that will help you produce code that will work on all server configurations.

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.