Hi friends,
it is weeks now I'm trying to figure out how to make simple custome theme engine for my custom PHP CMS. I want to use it for my projects. It is based on custom framework too. So I checked how Drupal does it and Joomla. They are complex but gave me little Idea.

What do I need to make a theme engine so that one can make a theme without knowing internal flow of the site articles, menus et al? Any article that talks of generic theme engine (not some specific CMS based)

I hope I have made clear myself.
Thanks

Recommended Answers

All 4 Replies

A CSS only theme can get you quite far I think. Just make sure your building blocks can be accessed by id's, and similar items by classes.

commented: why didn't I think of that? Thanks +13

A CSS only theme can get you quite far I think. Just make sure your building blocks can be accessed by id's, and similar items by classes.

Thanks.
Is there a way to make blocks accessible to backend where by I can assign block to something (article, links, menu et al) so that in combination to CSS I can change layout of the theme?

Thanks for great tip I didn't think of :)

Well, I use Smarty. I have predefined blocks for the backed ($MENU, $FOOTER, $CONTENT), which can be used in my theme template, if that's what you mean. That way, it is no longer dependant on CSS only (you can choose to not render stuff, instead of hiding it).

Well, I use Smarty. I have predefined blocks for the backed ($MENU, $FOOTER, $CONTENT), which can be used in my theme template, if that's what you mean. That way, it is no longer dependant on CSS only (you can choose to not render stuff, instead of hiding it).

cool! thanks you!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.