I am a big fan of Markdown (using it in almost all my PHP projects), but not a fan of its limited release. Most of the rendering is too simple, and in fact it does not allow me to control or free my layout. For example, I can insert an image:
! [Alt Text] (path / to / image.jpg) This is my image!
But it will just be converted to:
<p> <img src="path/to/image.jpg" alt="Alt Text" /> This is my image! </p>
Suppose I wanted to put an image to the right? Currently, I cannot add any classes to the syntax, but would it not be a good function? I would like to be able to output:
<p> <img src="path/to/image.jpg" alt="Alt Text" class="alignright caption"> This is my image! </p>
Support for one or more CSS classes would be phenomenal. My question is about the best way to implement this support in the PHP version of Markdown.
Ideas?
css php markdown
Sampson
source share