Problems, need help? Have a tip or advice? Post it here.
4 posts Page 1 of 1
Kind of silly question:

Where and what do i change so that richtext, will look like the front end.

I understand that i have to import the css from /root/css/style.css

but where to????


ANy help would be greatful
Hi,

Please see the docs on 'richtext' editable region -
http://www.couchcms.com/docs/tags-refer ... htext.html

The parameters specific to your needs would be 'css', 'body_id' and 'body_class'.

Hope this helps.
I attempted the solution you have in the docs.
But for whatever reasons it is not working. here is the code:

Code: Select all
<cms:editable name='Content' label='Description' css='/css/style.css' type='richtext' toolbar='full' >
<img src="/images/home_5.png" />
<img src="/images/home_4.png" />
<img src="/images/home_3.png" />
<img src="/images/home_2.png" />
<img src="/images/home_1.png" />
<span class="HMD">Company </span>text text text text text text text text text text
text text text text text text
text text text text text text
text text text text text text
text text text text text text
<br>
<span class="HMD">Call us at 00000 or 11100 for more information.</span>
</cms:editable>


ON the front end the images are floating right, and all the text is in the small caps.
while in the back end it is not.
Please use Chrome/FireFox tools to confirm is the CSS is indeed getting loaded in the admin-panel.
If it is, that is the most Couch can do for you.

From this point on, you'll have to find out what combination of CSS classes/IDs work together on the frontend to get the kind of display you want.

If the display on the front-end depends on a complex combination of CSS classes and IDs coming together, it is quite likely that simply injecting the CSS file in the backend will not suffice. You'll also need to recreate a similar CSS selectors hierarchy for the backend too for the proper display.

You can use the 'body_id' and 'body_class' parameters to provide specific id/classes to the document displayed within the wysywig editor and then, if needed, define new rules in CSS file to make the display within the editor match the frontend.

Hope this helps.
4 posts Page 1 of 1