On the ckeditor demo I see no way of switching the content's css.
There is mention of a plugin - is it just not installed on the demo?
What I'd like to achieve is the ability to switch the css (to arrive at a different background) thru the editor.
Is this possible?
<link rel="stylesheet" type="text/css" href="/templates/flyer_01_00.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Dark Green"
href="/templates/flyer_01_01.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Magenta"
href="/templates/flyer_01_02.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Gold"
href="/templates/flyer_01_03.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Aqua"
href="/templates/flyer_01_04.css" />
Thanks for your time,
michael
There is mention of a plugin - is it just not installed on the demo?
What I'd like to achieve is the ability to switch the css (to arrive at a different background) thru the editor.
Is this possible?
<link rel="stylesheet" type="text/css" href="/templates/flyer_01_00.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Dark Green"
href="/templates/flyer_01_01.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Magenta"
href="/templates/flyer_01_02.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Gold"
href="/templates/flyer_01_03.css" />
<link rel="alternate stylesheet" type="text/css" media="screen" title="Aqua"
href="/templates/flyer_01_04.css" />
Thanks for your time,
michael
Re: switching between content alt stylesheets
To initially apply a stylesheet, you can use the .contentsCss config entry. Just add that entry in one of the locations described in this Developer's Guide article.
In order to switch between them, I found this appendStyleSheet function attached to the document namespace that you could use.
The code would look like this:
Re: switching between content alt stylesheets
to make it all stick some voodoo ajax or js possibly will be required.
with FF & IE8, the alt.stylesheets can be selected in the view menu.
thanks also for the code examples.