Jump to content

Topic on Project:Support desk/Flow

[RESOLVED] provider migrated to php 5.5, wiki doesn't load

8
88.65.189.86 (talkcontribs)

Hello

my provider migrated two days ago to php 5.5, and since then my wiki (http://www.olliw.eu/storm32bgc-wiki/) doesn't load anymore.

my MediaWiki version is 1.23.2

I first thougfht that the issue is related to the .htaccess, which does a redirect:

<Files LocalSettings.php>

deny from all

</Files>

RewriteEngine On

RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f

RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-d

RewriteRule ^(.*)$ %{DOCUMENT_ROOT}/storm32bgc-wiki/index.php5 [L]

but removing it didn't help. Using the cntrl+U of firefox to watch the recieved html code displays the content of the file index.php5, i.e. it seems as if the require './index.php'; is not executed.

I'm at a loss, and would much appreciate any hint or tip or indication in which direction to look for.

Thx Olli

88.130.124.48 (talkcontribs)

Hi Olli!

Obviously files with the file extension php5 currently are sent to the user instead of being executed by PHP. How exactly this can be solved depends on the server setup. Most likely adding an according AddHandler directive to .htaccess helps.

Apart from that I don't see a reason why you should redirect everything to the index.php5 file - maybe you have already solved the problem, when you change the redirect to point to index.php instead?!

88.65.189.86 (talkcontribs)

Thanks a LOT for the answer, but I guess I don't understand

the index.php5 and index.php files are exactly those shipped with mediawiki, so, it's not like that I have done anything here

the server used to use the .php5, when I enter the url with .php it also uses the .php5, but this had been like that also before

the redirect doesn't seem to be the issue, at least then I remove that part from the .htaccess or delete the .htaccess completley, then the .php would yield a page not found error while the .php5 results in the same behavior, so it seems the server still goes for the .php5. I checked what you suggested and changed .php5 to .php in the redirect: one then gets some wiki info when entering the correct url, but it looks as if the layout is missing, and the home url doesn't work at all.

what I don't quite understand is why the behavior should have changed, I mean, the wiki is up and runing for 8 month now. As regards the .php5 vs .php thing my understanding was that MediaWiki would handle things correctly, irrespective of the providers preference.

My thoughts/conclusions might be totally nonsense, I'm just totally confused by what I see, it doesn't make sense to me.

I need to research what AddHandler does, can't comment hence, but many thanks for the hint.

THX

(BTW: I've contacted before the provider, but they refused to help)

88.65.189.86 (talkcontribs)

OK, your tip was great !!! it's nearly back to working

what occured to me was to also look at the LocalSettings.php, and indeed there the .php5 extension was specified. Together with your suggested change of the redirect, the wiki seems to work. It seems that the rules as regards the .php5 have changed.

The only thing which is not yet working is the url http://www.olliw.eu/storm32bgc-wiki/, somehow it isn't extended by the index.php (if one enters http://www.olliw.eu/storm32bgc-wiki/index.php it works).

Anyway, a BIG step forward, THANKS so much so far :)

88.130.124.48 (talkcontribs)

That URL is working for me currently; I had to clear the browser cache to actually see it.

It seems like your host has changed the handling of php5 files: Before their PHP update they obviously were parsed by PHP, after they are not. Given that your wiki is working correctly with the php files, I am not sure, if you still need correct handling for php5 files. Anyway, an example AddHandler directive for .htaccess might be one like this:

AddHandler x-httpd-php5.5 .php5

This should make php5 files be parsed by PHP 5.5 - assumed the host uses some default setup.

88.130.124.48 (talkcontribs)

Ahh, and you might be interested in doing a MediaWiki upgrade: MediaWiki 1.23.2 has known security issues. You should update to the current version of the 1.23 development branch. Currently that is 1.23.5!

151.225.136.51 (talkcontribs)

The current version now is 1.23.6. Which was released today.

88.65.189.86 (talkcontribs)

thanks! I too concluded that the .php5 handling has somehow changed (and obviously not consistently, an url is appended using the index.php5 file, but is not processed by php LOL). I currently solved the issue by simply renaming/erasing the file index.php5, so that index.php is called. That's why it works now after a cache upadte. I'm still looking for better solutions, since the .php5 vs .php thing breaks some other links, but at least the wiki is back! Yes, I know there is an upgrade to 1.23.5, but the release notes didn't indicated that it might solve the issue, and without having basic things working it's IMHO not wise to attempt an upgrade :) Thanks again to everyone!

Reply to "[RESOLVED] provider migrated to php 5.5, wiki doesn't load"