Not sure if PHP is working correctly
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Plusnet Community
- :
- Forum
- :
- Help with my Plusnet services
- :
- Everything else
- :
- Re: Not sure if PHP is working correctly
Not sure if PHP is working correctly
17-01-2008 9:22 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Just activated CGI, and mySQL on my plus net account yesterday, and I've tried uploading Wordpress to the site and going to the site in my browser but I always seem to get internal server errors.
The site is: http://ccgi.icehot.plus.com
Neither that works nor the install script: http://ccgi.icehot.plus.com/wp-admin/install.php
As far as I could tell plus net has the minimum requirements to run Wordpress, and I've changed the permissions of every file to 755 as well.
Re: Not sure if PHP is working correctly
17-01-2008 10:09 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
If you do, could you post the contents of it here, or PM me with them?
Re: Not sure if PHP is working correctly
17-01-2008 10:31 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Double checked that show hidden files was on, and I definately don't have a .htaccess file in there.
Re: Not sure if PHP is working correctly
17-01-2008 11:03 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Re: Not sure if PHP is working correctly
17-01-2008 12:23 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
What if you upload a simple PHP file named test.php as follows.
<?php
echo "test";
Re: Not sure if PHP is working correctly
17-01-2008 5:27 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
What it is is that the latest version of wordpress tries to log errors using the php "error_log" function, with the default setting for output. As we've not set up the "error_log" directive in the php config, this defaults to standard out.
There's a function run before any output to check for certain tables, and as they don't exist on a new install, it errors.
As we use cgiwrap on cgi for security, it sees these errors as headers, and as they aren't in the correct format for headers, it barfs, and gives the 500 server error.
To fix it, change line 163 of wp-includes/wp-db.php from:
error_log($error_str, 0);
to:
error_log($error_str . "\n", 3, '<your homedir>/wp-errors.log');
replacing <your homedir> with your homedir, e.g. /files/home1/username
Or alternitively comment out that line.
Re: Not sure if PHP is working correctly
17-01-2008 6:37 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Re: Not sure if PHP is working correctly
29-02-2008 11:42 AM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
I've got the same issue with Word Press Mulit User 1.3.3 (WPMU) version. It's throwing up a 500 Internal Server Error when I try to install WPMU.
I've looked for the same line of code within the wp-db.php but it's a different setup. I tried commenting the function print_error($str = '') but to no avail.
Has/Is anyone else having this issue, I'm pretty sure it's the same issue as Ben described above?
Thanks
Re: Not sure if PHP is working correctly
03-03-2008 3:34 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
wget http://mu.wordpress.org/latest.tar.gz
tar xzf latest.tar.gz
cd wordpress-mu-1.3.3/
find . -type f -name "*.php" -exec chmod +x '{}' \;
I then browsed to where it was installed, and followed the instructions on the page, and the site seems to be fine.
Re: Not sure if PHP is working correctly
03-03-2008 8:38 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
install_blog - ID: 1 URL: http://myURL.com/wp/ Title: Test WordPress database error: [Unknown column 'blog_public' in 'field list'] UPDATE wp_blogs SET blog_public = '1', last_updated = NOW() WHERE blog_id = '1'
The root http://myURL.com/wp/ throws up a 404. I've been through .htaccess with a fine tooth comb, write permissions, ftp'd and command line upload as you did.
The one thing that is displaying is the login, but it's lost all of the css so I'm thinking the .htaccess still isnt correct. If you can think of anything else let me know.
Thanks again
Jason
PS .htaccess
RewriteEngine On
RewriteBase /wp/
#uploaded files
RewriteRule ^(.*/)?files/$ /index.php
RewriteRule ^(.*/)?files/(.*) /wp-content/blogs.php?file=$2
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule . -
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2
RewriteRule . index.php
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Plusnet Community
- :
- Forum
- :
- Help with my Plusnet services
- :
- Everything else
- :
- Re: Not sure if PHP is working correctly