Topic on Project:Support desk

[RESOLVED] problems loading css

27
Summary by Ciencia Al Poder

Gentoo users: There seems to be a problem with Gentoo's PHP. See Thread:Project:Support_desk/Load.php causing segfault.

Message to people trying to post their problem on this thread: Without a detailed error message from the server's error log (and not just a 500 INTERNAL SERVER ERROR), there's no way we can figure out where's the problem and how to fix it. See Manual:How to debug for details about looking at the server's error log and enable debugging. If you can't provide a detailed error message, we won't be able to help you.

Saeros~mediawikiwiki (talkcontribs)

sometimes when I reload the page in the browser, it happens that the css does not get load...any idea why this happens?

I have installed the version 1.20.6

This is the address of the wiki: www.codegaia.com

This post was posted by Saeros~mediawikiwiki, but signed as Saeros.

AKlapper (WMF) (talkcontribs)
Saeros~mediawikiwiki (talkcontribs)

Thanks for the reply, but still I can not find the problem.

my browser console brand me the following problem:

GET http://www.codegaia.com/load.php?debug=false&lang=es&modules=mediawiki.legacy.commonPrint%2Cshared%7Cskins.vector&only=styles&skin=vector&* 500 (Internal Server Error) index.php:12

GET http://www.codegaia.com/load.php?debug=false&lang=es&modules=startup&only=scripts&skin=vector&* 500 (Internal Server Error) index.php:17

i have my wiki hosted in ipage, I don't know if the real problem is the hosting, i have tried installing previous versions but i had the same problems.

This post was posted by Saeros~mediawikiwiki, but signed as Saeros.

85.69.60.159 (talkcontribs)

Hi Saeros,

I have also the same problem with mediawiki 1.19.1 installed on ipage server. CSS doesn't load with Firefox once I reload the page but it does with Google Chrome for example.

The browser console of Firefox brand me the following problem:

[16:00:48,716] GET http://en.solarpedia.net/wiki/load.php?debug=false&lang=en&modules=mediawiki.legacy.commonPrint%2Cshared%7Cskins.vector&only=styles&skin=vector&* [HTTP/1.1 500 Internal Server Error 892ms]

[16:00:48,718] GET http://en.solarpedia.net/wiki/load.php?debug=false&lang=en&modules=startup&only=scripts&skin=vector&* [HTTP/1.1 500 Internal Server Error 636ms]

[16:00:48,719] GET http://en.solarpedia.net/wiki/load.php?debug=false&lang=en&modules=skins.vector&only=scripts&skin=vector&* [HTTP/1.1 500 Internal Server Error 1331ms]

I found otherwhere that's the problem is that the web server is configured to serve .css files as text/plain and not text/css.

Someone could resolve it ?

Vincent

Ciencia Al Poder (talkcontribs)

Vincent, the problem is not (only) it's sending CSS as text/plain, but the 500 Internal Server Error responses. Please check out the server error logs to get a detailed error message about what's failing.

85.69.60.159 (talkcontribs)

Ciencia, thank you for your reply. I found my problem. I added the code

body.page-Main_Page h1.firstHeading { display:none; } to commonElements.css in order to not have the title in Main Page. I deleted this line, and now it's working !

I have just to find another way to not have the title in Main Page.

Vincent

85.69.60.159 (talkcontribs)

Sorry, I spoke to fast.. It's still not resolved..

Vincent

Theking2 (talkcontribs)

Interestingly en.wikipedia.org suffers from the same problem. I have (obvisouly) no access to their log files but the following URL resulted in a 500 Error reported in Firefox: http://bits.wikimedia.org/de.wikipedia.org/load.php?debug=false&lang=de&modules=ext.flaggedRevs.basic|ext.gadget.CommonsDirekt,WikiMiniAtlas|ext.rtlcite,wikihiero|ext.uls.nojs|ext.visualEditor.viewPageTarget.noscript|mediawiki.legacy.commonPrint,shared|mediawiki.ui.button|skins.common.interface|skins.vector.styles&only=styles&skin=vector&* Theking2 (talk) 07:33, 28 March 2014 (UTC)

Theking2 (talkcontribs)

Interestingly en.wikipedia.org suffers from the same problem. I have (obvisouly) no access to their log files but the following URL resulted in a 500 Error reported in Firefox: http://bits.wikimedia.org/de.wikipedia.org/load.php?debug=false&lang=de&modules=ext.flaggedRevs.basic|ext.gadget.CommonsDirekt,WikiMiniAtlas|ext.rtlcite,wikihiero|ext.uls.nojs|ext.visualEditor.viewPageTarget.noscript|mediawiki.legacy.commonPrint,shared|mediawiki.ui.button|skins.common.interface|skins.vector.styles&only=styles&skin=vector&* Theking2 (talk) 07:33, 28 March 2014 (UTC)

81.58.150.73 (talkcontribs)

Hi Saeros,

I have exactly the same problem. I have visited your website, but you have no reload problems anymore.

What did you change?

Jos

Ciencia Al Poder (talkcontribs)

Jos, 500 errors can be produced by various issues. Without knowing which exact error do you have, you can't assure you have the exactly the same problem. Read Manual:How to debug and come back with the detailed PHP error you get

81.58.150.73 (talkcontribs)

Hi Saeros,

I have done all the debugging I could, but no PHP errors, all I could see -using firebug- was the 500 internal server error. My hosting company is FatCow.

Any help would be appreciated,

Thanks, Jos

85.69.60.159 (talkcontribs)

Hi,

This problem has been mentioned here recently : Manual:Load.php

I tried to fix it by adding a RewriteRule in the file .htaccess. However, styles don't display everytime with Firefox, and half the time with google. I have mediawiki 1.19.1 and PHP 5.2.17. My hosting company is IPage.

What can be wrong ?

Vincent

JosNederland (talkcontribs)

Hi Vincent,

I discovered that loap.php is sometimes not loaded (500 internal server error), so the RewriteRule in .htaccess has no effect.

Now I use a very dirty hack, I am loading the css the "old" way... I use the skin cologneblue. Edit your own skin.php for instance skins/vector.php.

In the skin file look for

function setupSkinUserCss

and (in my case) add:

$out->addStyle( 'cologneblue/screen.css', 'screen' );

So

$out->addStyle( 'cologneblue/screen.css', 'screen' );

generates in the html file:

<link rel="stylesheet" href="/skins/cologneblue/screen.css?303" media="screen" />

It is working 100% of the time.

Good luck, Jos

88.130.64.88 (talkcontribs)

Hi Jos,

that is really dirty. Instead of fixing the symptoms, you should cure the cause! Get more details about the 500 server error and fix that one instead!

85.69.60.159 (talkcontribs)

Hi Jos,

Thank you very much ! That's maybe dirty but it's works! I don't know if it is possible to fix it otherwise when we can't configure the server (My hosting company is IPage.)

So I added the $out->addStyle( 'vector/screen.css', 'screen' ); line inside the function unction setupSkinUserCss of the skins/vector.php file and know it is working for Firefox and Google Chrome all the time ;) Thx! Vincent

80.47.255.190 (talkcontribs)

I have been having exactly the same symptoms. My server provider is iPage and I have installed mediaWiki version 1.21.2. Same 500 server error on alternate refresh requests from Chrome and on every refresh request on Explorer. Unfortunately the $out->addStyle( 'vector/screen.css', 'screen' ); fix proposed by Jos/Vincent did not work for me. The upshot of this hack is that the it seems to result in a partial style sheet being loaded, but the 500 server error continues and the style is still corrupted. Also I tried adding $wgResourceLoaderDebug=true to LocalSettings.php, no fix here either.... Any other ideas? Guy

Shiroi Hane (talkcontribs)

Have you tried manually changing debug=false to debug=true in the load.php query string for the CSS? That's what tipped me off to the workaround that helped for me, and it's possible I wrote something incorrectly in my earlier post. Since then I have upgraded to a newer version of MW to no avail, and tried fishing with various .htaccess and php.ini settings.

Ciencia Al Poder (talkcontribs)

Still, without a descriptive error message we can't help you with that problem.

80.47.255.190 (talkcontribs)

Thanks. Yes, I can confirm that the problem is not present when I enable the resource loader debug. This does not help much though as no work-around is obvious to me and I would rather not leave debug turned on.

Guy

Mgutt (talkcontribs)
24.39.1.140 (talkcontribs)

It worked for me.

Ciencia Al Poder (talkcontribs)

Jos, 500 errors can be produced by various issues. Without knowing which exact error do you have, you can't assure you have the exactly the same problem. Read Manual:How to debug and come back with the detailed PHP error you get

Shiroi Hane (talkcontribs)

I've been having the same problem for some time, and found my way here when I discovered that load.php?debug=false&lang=en&modules=skins.vector&only=styles&skin=vector&* was producing an error 500 50% of the time. None of the fixes mentioned above help in any way. Nothing is appearing in the script error logs and no amount of changes to the error logging settings in php.ini make any errors appear. What I did discover, however, is that the problem goes away if I change the string to debug=true and thus I can work around the problem by adding $wgResourceLoaderDebug=true to LocalSettings.php, although what other effects that may have I do not know.

Caswick (talkcontribs)

Exact same url, exact same problem, works half the time, doesn't work half the time for Firefox users using the same version and same environment. The fix is the same, turn $wgResourceLoaderDebug=true in LocalSettings.php, now all our users are happy. I'm leaving it on permanently.

114.199.38.31 (talkcontribs)

I'm having the same error. However, after activating all kind of debugs that are documented in the Manual:How to debug, no error is printed, either in the log or in the resulting web page. After examining the apache error log when loading the url:

http://localhost/load.php?debug=false&lang=en&modules=mediawiki.legacy.commonPrint%2Cshared%7Cskins.monobook&only=styles&skin=monobook&*

I get the following:

[Sat Nov 16 13:49:17 2013] [notice] child pid 30542 exit signal Segmentation fault (11)

So it seems it's an error with PHP itself. The PHP version I'm using is 5.3.23-pl0-gentoo.

Ciencia Al Poder (talkcontribs)