#Can't change the body background image for a specific page

11 messages · Page 1 of 1 (latest)

unreal ravine
#

I have a page called "Template:DaysUnionStyle.css" with a bit of CSS code in it that is added to another page via {{#css:Template:DaysUnionStyle.css}} that gives the page a style different from other pages on the wiki, however, all code in the screenshot works, except for when "background-image" is added below "body", and I am not sure why this line of code does not work.
How would I fix this?
Page:
https://mythcommunity.miraheze.org/wiki/Template:DaysUnionStyle.css
Page that the template is used in:
https://mythcommunity.miraheze.org/wiki/Great_Day

Myth Community Wiki

@media (min-width: 1340px) {

body {
background-image: url(https://static.wikitide.net/mythcommunitywiki/2/22/DaysUnionStyleBackground.png);
}
#mw-content {
border: 3px solid #49ba6d;
box-shadow: 0px 0px 10px 5px #49ba6d;
}
#mw-header-container {
outline: #487e65 solid 5px;
}

}

Myth Community Wiki
steady hazel
#

Perhaps that template uses TemplateStyles?
You might try enabling the TemplateStylesExtender

steady hazel
#

Special:ManageWiki/extensions

unreal ravine
steady hazel
#

Sorry for the confusion if you are not using it.
But it is useful and I urge you to try this.
https://www.mediawiki.org/wiki/Extension:TemplateStyles

MediaWiki

TemplateStyles is a parser extension that allows users to store custom CSS code on wiki pages and to embed these styles into articles via the ‎<templatestyles> tag. The extension allows only a safe subset of CSS syntax stored in embeddable style pages. This is powered by the css-sanitizer library.
Editors are encouraged to include styles for a t...

unreal ravine
#

Yes I was just looking at that, but thank you regardless lol

open thistle
unreal ravine
open thistle
median swallow