Has anyone configured online output with a user option to switch dynamically between 2 stylesheets for the same content? Similar to the way CSS Zen Garden works. I will look into that mechanism in more detail, but thought I'd start a conversation here also.
The scenario is: a UI that has 2 designs: a dark UI and a light UI. I am just wondering if I can match the online help dynamically on user input...?
Thanks,
Tom
Dynamic stylesheet-switching after output
-
atomdocs
- Sr. Propeller Head
- Posts: 308
- Joined: Tue Jun 18, 2013 3:00 am
- Location: Eastern Seaboard, Thailand
- Contact:
Dynamic stylesheet-switching after output
Tom
Flare 2022, Capture 7

Flare 2022, Capture 7

-
kwag_myers
- Propellus Maximus
- Posts: 810
- Joined: Wed Jul 25, 2012 11:36 am
- Location: Ann Arbor, MI
Re: Dynamic stylesheet-switching after output
Have you considered using the Conditional Text settings in the Properties of each StyleSheet?
"I'm tryin' to think, but nothin' happens!" - Curly Joe Howard
Re: Dynamic stylesheet-switching after output
That's an interesting question. You'd have to add a button to the toolbar with some Javascript, but the problem is having it retain that different stylesheet as the user navigated the help.
What might be easier is to create two outputs, one pointing to one stylesheet and one pointing to the other. You upload the two outputs to different folders on the web server, then the button you create in the toolbar basically makes a CSH call to the other help. It would be tricky because 1) it would have to dynamically determine which topic you were viewing so it could be included in the CSH call, and 2) I would assume you'd like the same appearance to reappear the next time the user loads the help, which would involve creating and invoking a cookie.
What might be easier is to create two outputs, one pointing to one stylesheet and one pointing to the other. You upload the two outputs to different folders on the web server, then the button you create in the toolbar basically makes a CSH call to the other help. It would be tricky because 1) it would have to dynamically determine which topic you were viewing so it could be included in the CSH call, and 2) I would assume you'd like the same appearance to reappear the next time the user loads the help, which would involve creating and invoking a cookie.
Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
-
atomdocs
- Sr. Propeller Head
- Posts: 308
- Joined: Tue Jun 18, 2013 3:00 am
- Location: Eastern Seaboard, Thailand
- Contact:
Re: Dynamic stylesheet-switching after output
Thanks, I'll take a look at these suggestions. At the moment, I don't think I need to use conditional text. I expect there might be some javascript involved. I will also investigate the alternate stylesheet function of CSS. My original thought was to be able to control the colour scheme, which is a "nice to have", I suppose. But now I have found a more valid purpose - changing the size of fonts. The help will be part of a closed system, and this function has featured frequently on wish lists during user testing.
Tom
Flare 2022, Capture 7

Flare 2022, Capture 7

Re: Dynamic stylesheet-switching after output
If you haven't already got this figured out, you might want to take a look at Thomas Tregner's blog post "Version Filters in HTML 5 Output" (http://tregner.com/flare-blog/version-f ... l5-output/), on his Flare for Programmers blog. It provides details and a sample project that describe a method you could use to do a version of what you are trying to do, if you use the idea of multiple outputs that use different stylesheets.
Hope this helps,
Nancy
Hope this helps,
Nancy
Nancy Hutson Hale
Director, Education Services
SalesPage Technologies
http://www.salespage.com
Certified MAD for Flare
Director, Education Services
SalesPage Technologies
http://www.salespage.com
Certified MAD for Flare