Jump to:

23370 Posts in 18160 Topics by 2864 members

General Questions

SilverStripe Forums » General Questions » Page Formatting Issue

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 761 Views
  • owaiskl
    Avatar
    Community Member
    16 Posts

    Page Formatting Issue Link to this post

    Hey all,

    I was wondering if anyone knows why when putting in an image onto a page using the CMS content editor, the editor allows me set wrapping and alignment for the image, but when I save and publish the page the text never wraps around the image, and the alignment is always 'left'. Any ideas on what the cause is?

  • MateuszU
    Avatar
    Community Member
    89 Posts

    Re: Page Formatting Issue Link to this post

    Hi,
    Sounds like CSS issue. How do you set the wrapping? Do you set it when inserting the image, via the dropdown, or do you set it afterwards in the editor itself?

    Anyways, after you add the image, click on the HTML button in the tinyMCE to browse the html source and note how the inserted img tag looks like. It should have a class attribute appended to it, like that:

    <p><img class="left" src="assets/importedfiles/webcam3small.jpg?r=87997" width="200" height="150" /></p>

    The 'left' class should be present in your typography.css file and it should contain 'float: left' for the text to wrap around the images.

    mat.

  • owaiskl
    Avatar
    Community Member
    16 Posts

    Re: Page Formatting Issue Link to this post

    Yep, the css was the culprit. I was missing the .left {float :left;) designation, which was why the html was fine, but it wouldnt look right.

    Thanks for your help!

    761 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.