Easy HTML Templates with Mustache

  You are currently not logged in. You can view the forums, but cannot post messages. Log In | Register

27-Apr-12 00:00
This is a forum topic for discussing the article "Easy HTML Templates with Mustache":

http://www.elated.com/articles/easy-html-templates-with-mustache/

Learn how to create HTML templates using Mustache, the easy-to-use, logic-less template system.
27-Apr-12 07:42
This is cool technology for templates.
I will surely invest time in this complete tutorial.
I have used demos.
Can anyone tell me list of tool or tools from which i can make my own logo with ease?
I am not a designer, just need for my clients.
So, for this i am not going to learn photoshop like tools.
Mean while, Thanks Matt for introduction of Mustache!
08-Dec-12 17:57
Matt

Great tutorial.
What is the best way to use Mustache with your 'CMS in an Afternoon'?

Thanks
Phil
08-Dec-12 19:55
Matt

Please, could you redo this tutorial but in PHP?

Thanks again

Phil
18-Dec-12 19:08
@philatnotable: Never done it, but it should be straightforward. Grab the PHP implementation here: https://github.com/bobthecow/mustache.php

Then just create your Mustache templates in the CMS templates folder, and replace the simple template require() calls in the PHP code with calls to $m->render(), passing in the loaded template and an array containing the appropriate variables for the template.

--
Matt Doyle, Elated
3rd Edition of my jQuery Mobile book out now! Learn to build mobile web apps. Free sample chapter: http://store.elated.com/
18-Dec-12 23:58
Thanks Matt,

I can get Mustache to work, following your direction, up until I try to turn this:

return ( array ( "results" => $list, "totalRows" => $totalRows[0] )

into a simple Mustache ready array.

Regards, Phil
20-Dec-12 08:35
That statement is a closing paranthesis short.

--
Chris.
So long, and thanks for all the fish.
http://webmaster-talk.eu/

 
New posts
Old posts

Follow Elated