|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
gtgibson Smarty Rookie
Joined: 30 Jul 2003 Posts: 9 Location: New Zealand
|
Posted: Wed Jul 30, 2003 8:16 am Post subject: How to use smarty smartly? |
|
|
Another question, this time about managing a site using Smarty.
I want to have the files in my web application spread out over multiple directories. I have over 50 individual pages in the website, each with dynamic content. (Content stored in a database).
Is it OK to store the templates all in one big fat directory, and have the pages in a website spreadout over lots of directories?
Or should I be using a CMS with smarty? If so, what CMS?
Are there sites out there using a CMS with only one index.php page, and a query string (e.g. ?pageID=5) to pull a template file and logic file out of a database?
Lots of questions I know, but I am wanting to make a fairly big site, and have little idea of where to start.
GG _________________ I suck at web development. |
|
Back to top |
|
boots Administrator
Joined: 16 Apr 2003 Posts: 5611 Location: Toronto, Canada
|
Posted: Wed Jul 30, 2003 4:04 pm Post subject: Re: How to use smarty smartly? |
|
|
gtgibson wrote: |
Is it OK to store the templates all in one big fat directory, and have the pages in a website spreadout over lots of directories? |
Absolutely. HOWEVER, you may have to make your templates "aware" of the relative path (or depth) that they are being called from as this could affect RELATIVE access to other resources (images, form handlers, etc).
gtgibson wrote: | Or should I be using a CMS with smarty? If so, what CMS? |
Only you can answer that. Smarty provides tools, you still have a lot of work to do to get a working system of any sort. There is a lot of benefit leveraging existing code. Still, you may prefer to roll-your own depending on your requirements.
gtgibson wrote: | Are there sites out there using a CMS with only one index.php page, and a query string (e.g. ?pageID=5) to pull a template file and logic file out of a database? |
Yes, of course. There are also many using apache force-type tricks (and others) which hide those details.
gtgibson wrote: | Lots of questions I know, but I am wanting to make a fairly big site, and have little idea of where to start. |
Well, do read the material here at the Wiki and elsewhere. There are some excellent articles available on the net. Start small and don't be afraid to experiment, of course. Remember, Smarty is a tool, a part of your solution, yes, but not the whole enchilada!
GOOD LUCK! |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|