invalid background-color: none

This forum is for all Flare issues related to styles, stylesheets and XML.
Post Reply
pdenchfield
Propellus Maximus
Posts: 574
Joined: Tue Oct 03, 2006 7:56 am
Location: Seattle, WA
Contact:

invalid background-color: none

Post by pdenchfield »

The <body> tag in our stylesheet is set to a gray background color for the default medium, for our WebHelp output. We don't want a background color for PDF output, so we set <body> in the print medium to "background-color: none" as directed by tech support - is there a better, more "valid" value for this attribute?

I keep getting this message when I open a topic. Mildly annoying. What CSS edit do I need to do to make this error message stop displaying every time I open a topic?

CSS: A:\Projects_Current\Edge\Edge_UG_1.2_P15200-03\Source\Edge\Content\Topics_Edge\Abbreviations.htm: CSS: Invalid background-color: none
invalid-background-color-message.png
SonoSite_Shared_Ch_ENG.css
You do not have the required permissions to view the files attached to this post.
NorthEast
Master Propellus Maximus
Posts: 6426
Joined: Mon Mar 05, 2007 8:33 am

Re: invalid background-color: none

Post by NorthEast »

The correct (and default) colour is transparent.

W3Schools is good for any CSS questions:
http://www.w3schools.com/cssref/pr_background-color.asp

It would make more sense to not set the colour in default medium, and instead only set it in the medium used by the help (e.g. non-print); otherwise you're having to set things twice, instead of just once.
pdenchfield
Propellus Maximus
Posts: 574
Joined: Tue Oct 03, 2006 7:56 am
Location: Seattle, WA
Contact:

Re: invalid background-color: none

Post by pdenchfield »

Thanks, Dave. Our stylesheet is set up to use the default medium for its online outputs (WebHelp only at this point). Would you recommend using a different medium for online outputs? (such as non-print or a custom medium)
NorthEast
Master Propellus Maximus
Posts: 6426
Joined: Mon Mar 05, 2007 8:33 am

Re: invalid background-color: none

Post by NorthEast »

pdenchfield wrote:Thanks, Dave. Our stylesheet is set up to use the default medium for its online outputs (WebHelp only at this point). Would you recommend using a different medium for online outputs? (such as non-print or a custom medium)
Yes, I'd recommend using a separate medium for help/online, in the same way that you use a print medium. I use a medium for any target that has its own unique styles (you can add your own mediums).

The reason I suggest this is because:
1) If you have separate mediums for both the help and print outputs, it means you can look at these mediums and see exactly what styles/properties are modified specifically for those outputs; i.e. it's obvious what is different in the help/print from the 'default'. If you have styles that are specific to help (or any target) in the 'Default' medium (i.e. no medium), then it means you don't have that separation, and you can't see which styles in the 'Default' medium are specific to the help.
2) The styles in 'Default' (no medium) are inherited by all mediums; so say you include a help-only style in 'Default', then this will be inherited in your 'print' medium, so you then have to override/reset it in the 'print' medium. If the help-only style is in the 'non-print' medium to start with, then it'll never be inherited by 'print' (or any other medium).
pdenchfield
Propellus Maximus
Posts: 574
Joined: Tue Oct 03, 2006 7:56 am
Location: Seattle, WA
Contact:

Re: invalid background-color: none

Post by pdenchfield »

Thanks, Dave. Illuminating post as usual. :-)
Post Reply