Using Markdown in CakePHP

Posted July 10th, 2011 • 1 min read

Markdown rocks. I lately fell in love with it when I was setting up this very blog. You can just write easy-to-read and easy-to-write plain text files, and Markdown takes care of the rest.

For this blog I had used a Markdown script I found that parses plain text and outputs it as HTML. It allows me to write posts in a simple/plain format and just pump it into the database as is. For a while I wanted to make it into a more solid CakePHP Helper. And today I did. Setting it up couldn't be simpler, and using it is a matter of adding it as a call in your views.

I put it on Github @ Markdown for CakePHP along with the necessary instructions and usage example.

Hope you enjoy it, and if you have any suggestions or tips, don't hesitate to leave a comment or Fork it.

Stay up to date

Want to know when a new post comes out and stay in the loop on tips, tricks and gotchas? Consider signing up for the Mindthecode newsletter.

Comments

Keep reading

February 11th, 2012 • 2 min read
The Spotify Preview build has expired
April 14th, 2011 • 3 min read
I heard a lot about SASS, mostly a lot of people raving about how it was the best thing since chocolate.
October 8th, 2015 • 2 min read
As I was playing around with the awesome React Native library I encountered a few small hicups getting an app running on an actual device, so here's how I made it work for me.