enkreativbyra
Veteran
Just Getting Started
Member Likes (0)
Fresh install of WP 3.4 RC1 with subdomains. Using Mamp Pro and have added a custom domain in terminal (sitename.lo). Also I have moved the wp-content folder to another structure using the built in WP functionality. So I changed url in the hardcoded db.php file.
This three messages appear when trying to access the admin area (which I can access). In the frontend, only the top one is displayed.
Warning: mysql_set_charset() expects parameter 2 to be resource, boolean given in /Users/*SITELOCATION*/wp-includes/wp-db.php on line 554
Warning: Cannot modify header information - headers already sent by (output started at /Users/*SITELOCATION*/wp-includes/wp-db.php:554) in /Users/*SITELOCATION*/wp-includes/option.php on line 563
Warning: Cannot modify header information - headers already sent by (output started at /Users/*SITELOCATION*wp-includes/wp-db.php:554) in /Users/*SITELOCATION*/wp-includes/option.php on line 564

Responses (6)
Support Chimp (joined March 2010) Likes (0)
Hey there.
The headers already sent is usually a rogue space before some php tags <?php
You can checkout the files db.php and db-config.php you edited and uploaded for this.
Let me know how you get on.
Take care.
Member (joined August 2011) Likes (0)
Hi!
It was a blank line at the bottom of db.php, but I still see the mysql_set_charset error.
And when I try to login it doesn't redirect to admin, but when I go to admin/network it works. And then I can access just admin as well.
EDIT
Sorry, tested it some more and in the subsites it still shows the header warning and the mysql warning.
Warning: Cannot modify header information - headers already sent by (output started at /Users/*SITELOCATION*/wp-includes/wp-db.php:554) in /Users/*SITELOCATION*/wp-includes/option.php on line 564
Any ideas?
Thank you!
Member (joined August 2011) Likes (0)
It also says:
Warning: Cannot modify header information - headers already sent by (output started at /Users/*SITELOCATION*/wp-includes/wp-db.php:554) in /Users/*SITELOCATION*/wp-includes/pluggable.php on line 881when I try to add, bin or delete posts/pages, or update anything in general in both main and sub-sites.
It seems like it's the following snippet from wp-db.php that is screwing things up. (Line 26 is line 554)
Help is greatly appreciated!
Support Chimp (joined March 2010) Likes (0)
I wasn't seeing this on my installs but I'm wondering if there are more spaces in there.
It might be worth trying with a fresh set of files.
I'll ping barry our plugin develop on this one regarding the mysql issue, He may have seen this before in multi-db.
Take care
Member (joined August 2011) Likes (0)
Hold your horses!
Did a fresh install and also made use of the db-list.php file. Voila! Everything is up and running smoothly.
No need to worry any more! Thanks for your help :)
Support Chimp (joined March 2010) Likes (0)
Thats awesome.
I suggested the fresh set of files suspecting that somewhere along the lines something was corrupted or a rogue space got in there.
Thanks for letting me know, glad you have this sorted now! :)
Take care and have a great week! :)
Become a member