pages without smarty parsing, using own template instead

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
dub27

pages without smarty parsing, using own template instead

Post by dub27 »

Hi, I have looked through the forum and documentation and could not really find an answer to this question:

Is it possible to use cmsmadesimple without using smarty templates and parser, ie using my own templates and css, php, content calls for page data population. 

I guess, it is unclear without deep review of the code, to see if smarty is essential or if it can be worked around just for template content population.

Thanks in advance for any feedback...

D27
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: pages without smarty parsing, using own template instead

Post by calguy1000 »

smarty is definately very core to the system, and is what provides all of the dynamic content. 

Why would you not want to use smarty?
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am
Location: Deatsville, AL

Re: pages without smarty parsing, using own template instead

Post by Elijah Lofgren »

dub27 wrote: Is it possible to use cmsmadesimple without using smarty templates and parser, ie using my own templates and css, php, content calls for page data population. 
Yes, it is. But it seems like it would make using CMSMS pointless.  ;)
One way would be to edit config.php and change this:

Code: Select all

$config['use_smarty_php_tags'] = false;
to:

Code: Select all

$config['use_smarty_php_tags'] = true;
Then in your template you could use php code directly something like this:

Code: Select all

<__html>
<head>
<title>{php} [php code to fetch title here] {/php}</title>
</head>
</__body>
{php} [php code to fetch title here] {/php}
<__body>
</__html>
Another way would be to use User Defined Tags, but I still don't see why you would want to do thing this way.  ;)
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
dub27

Re: pages without smarty parsing, using own template instead

Post by dub27 »

Thanks for the info...

There are many reasons, just depends are on where one stands in relation to template parsing and using php code versus an interface such as smarty.  My preference is to to query directly using php... but really like the cms ms framework, very clean, well thought out and I did my homework... been investigating cms for the past 6 weeks...

To clarify, is smart providing all parsing, caching etc?  That is, is smarty the template parsing engine and caching engine or are these separate?  I am trying to get an overall map of the flow?

Thanks again,

D
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm
Location: Fairless Hills, Pa USA

Re: pages without smarty parsing, using own template instead

Post by Ted »

Smarty basically works as template, caching (somewhat -- we don't use full caching) and composition engine.  CMSMS basically provides all the pieces and smarty puts them all together starting with the template down. Plus, we get the added benefit of a nice complete template language that people can use.

In theory, I could've coded all this by hand and used instead, but it makes for a much cleaner/unified interface for the users.

Though, I'm wishing we did {{ }} instead of { }.  Oh well.  :)
dub27

Re: pages without smarty parsing, using own template instead

Post by dub27 »

Hi, thanks for the feedback... that is what I thought and makes sense for most end users... just so happens I need to build more into the system I am developing... 

If you don't mind my saying -- well done -- a superb cms system.  And you rank very well on opensourcecms and cmsmatrix aswell, no mean feat.

I pretty much tried out most of the cms' available in the market, some opensource, some commercial and it was a breathe of fresh air to walk through your site, your documentation and your system. 

Thanks again,

D
Post Reply

Return to “Developers Discussion”