Topic on Project:Support desk

Activates HTTPS and now CSS didnt seem to load

9
RHuschmidt (talkcontribs)

Hi there

i activates HTTPS on Apache2 for my Wiki and now CSS do not load.

i already modified ""$wgServer" from the http://IP to HTTPS://SUBDOMAIN.DOMAIN.DE

Do you have any Idea for this Case? i've already looked at some Threats but only found the "solution" with "$wgServer"


Kind Regards,

Rob

MarkAHershberger (talkcontribs)

Can you share your wiki's url? We may be able to see a problem.

What version of MediaWiki are you using?

Does your browser's console say anything about the style links?

RHuschmidt (talkcontribs)

Hi Mark,


wiki.****.de *i blanked the URL afterwards.


"Does your browser's console say anything about the style links?"

- i have to translate it:

- load error <script> for the source: "https://wiki.innenausbau-fudala.de/wiki/load.php?debug=false&lang=de&modules=startup&only=scripts&skin=vector".


so this is beside that Mutation Events shoudnt be used anymore.


Also the Links dont work anymore. For Example: "Login".

In the SSL Configuration i configured that all traffic is "routed" to https, maybe this is a problem?


Hope you can understand my bad english :)

Ciencia Al Poder (talkcontribs)

Apparently, something more has been changed beyond "https".

Your wiki seems to expect the installation to be in /wiki/index.php but it seems to be in /index.php instead. Have you moved your wiki?

Check if $wgScriptPath is correctly set.

RHuschmidt (talkcontribs)

my wiki is in "/var/www/html/wiki" and i didnt moved it so far.


i installed the wiki under the path above and went under http through the installation (GUI Webbrowser) after setting the wiki up and testing the login i activated https with Certbot and the result is viewable.


The Path:


## The URL base path to the directory containing the wiki;

## defaults for all runtime URL paths are based off of this.

## For more information on customizing the URLs

## (like /w/index.php/Page_title to /wiki/Page_title) please see:

## https://www.mediawiki.org/wiki/Manual:Short_URL

$wgScriptPath = "/wiki";


And Documentroot:

DocumentRoot /var/www/html/wiki


Hope this helps :)


Thank you so much so far.


2001:16B8:109B:7300:11B5:3D03:8DBE:9E48 (talkcontribs)

There is your problem:

> $wgScriptPath = "/wiki";

> And Documentroot:

> DocumentRoot /var/www/html/wiki

When I remove the "/wiki" from your URL, then I am able to load the stylesheet. I am not sure of the best solution currently, but if you e.g. remove the "/wiki" from DocumentRoot, at least the stylesheet should be found again.

RHuschmidt (talkcontribs)

Thank you!


If i remove /wiki from my DocumentRoot, then my site wont load. I have to use multible Documentroots with multible virtual host because i want to host multible sites.

i also tried to remove /wiki from localsettings.php. but this also changed nothing :(

MarkAHershberger (talkcontribs)

I think the solution is to leave your DocumentRoot alone and change $wgScriptPath to:

$wgScriptPath="";
RHuschmidt (talkcontribs)

@Mark i think this is it!


my mistake in this case: i changed "/wiki" to "/" because i tought of "root directory"

$wgScriptPath=""; helped alot! thank you and all others very much for you quick help :D