Search code examples
cssmarkdownpagedown

Pagedown Markdown editor : issue with images


When using PageDown, there is some problem when inserting an image which is too big.

It is not redimensioned to a size that would fit in the editor's width (that would be possible with <img src="" width="...">)

Example : try to insert this image URL http://upload.wikimedia.org/wikipedia/commons/4/4b/Apple_pie.jpg in this editor :

http://www.markitdown.net/markdown.

How to make image fit in the container with Markdown ? (this is done on StackOverflow's editor)


Solution

  • When working with the Pagedown editor

    http://pagedown.googlecode.com/hg/demo/browser/demo.html

    it finally works by adding

    #wmd-preview img { max-width: 500px; }
    

    All images (even big ones) will have a max width of 500px.