UseBB Community

The official board for UseBB help and discussion

UseBB Community » 2.x Discussion » Templating engine idea

Templating engine idea

Page: 1

Author Post
Member
Registered: Jan 2008
Posts: 16
An idea to add some more logic and structure into templating.

For instance: Quick Reply

This is always part of a topic template. Why not use switches in the templating system?
Something like:
view_topic.tpl
<div id="forum">
[..]
some title stuff, breadcrumbs,category, new topic, new reply, etc..
[..]
<div id="topic_title">{$title}</div>
{begin_loop_posts}
<div id="{post_id}>
...
</div>
{end_loop_posts}
{if_quick_reply}
<div id="quick_reply">
markup goes here
</div>
{enfid_quick_reply}
..
some other shit here
..
</div>


Using these if's in templates, you can really template everything you want.
When the template is parsed, the parses checks if the quick_reply should be shown or not.

In this case, the designer has complete control over the lay-out, and the position where he/she wants the information.

This idea isn't mine, I've seen it in a CMS, and have templated it. The power and the control the designer has, is endless..
Developer
Registered: Apr 2004
Posts: 2180
Location: Belgium
What you are suggesting here has been on the list for UseBB 2 since years. In fact, it was decided to use template files in PHP but allow other systems (such as Smarty) to be used. See the mailing list.
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog

Page: 1

UseBB Community » 2.x Discussion » Templating engine idea

UseBB Community is powered by UseBB 1 Forum Software