mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 10:24:26 +02:00
update FAQ
This commit is contained in:
21
FAQ
21
FAQ
@@ -1,6 +1,8 @@
|
||||
QUESTION INDEX
|
||||
--------------
|
||||
|
||||
GENERAL
|
||||
|
||||
Q: What is Smarty?
|
||||
Q: What's the difference between Smarty and other template engines?
|
||||
Q: What do you mean "Compiled PHP Scripts" ?
|
||||
@@ -13,6 +15,13 @@ Q: Do you have a mailing list?
|
||||
Q: Can you change the mailing list so reply-to sends to the list and not the
|
||||
user?
|
||||
|
||||
HOWTO
|
||||
|
||||
Q: How do I generate different cache files per template based on arguments
|
||||
passed to the page?
|
||||
|
||||
TROUBLESHOOTING
|
||||
|
||||
Q: Smarty doesn't work.
|
||||
Q: I get the following error when running Smarty:
|
||||
Warning: Wrong parameter count for preg_replace() in
|
||||
@@ -34,6 +43,8 @@ Q: My ISP did not setup the PEAR repository, nor will they set it up. How do I
|
||||
make Smarty run without it?
|
||||
Q: Javascript is causing Smarty errors in my templates.
|
||||
|
||||
MISC
|
||||
|
||||
Q: Can I use Macromedia's Dreamweaver to edit my templates?
|
||||
Q: Dreamweaver is urlencoding the template delimiters when they are in a SRC or
|
||||
HREF link. How do I get around this?
|
||||
@@ -118,6 +129,12 @@ A: Yes we could, but no we won't. Use "Reply-All" in your e-mail client to send
|
||||
to the list. http://www.unicom.com/pw/reply-to-harmful.html
|
||||
|
||||
|
||||
HOWTO
|
||||
-----
|
||||
Q: How do I generate different cache files per template based on arguments
|
||||
passed to the page?
|
||||
A: Pass $REQUEST_URI as the cache_id when you display() or fetch() a page.
|
||||
|
||||
TROUBLESHOOTING
|
||||
---------------
|
||||
|
||||
@@ -188,8 +205,8 @@ A: The easiest thing to do is grab all of PEAR and install it locally for your
|
||||
Q: Javascript is causing Smarty errors in my templates.
|
||||
A: Surround your javascript with {literal}{/literal} tags. See the docs.
|
||||
|
||||
DREAMWEAVER
|
||||
-----------
|
||||
MISC
|
||||
----
|
||||
|
||||
Q: Can I use Macromedia's Dreamweaver to edit my templates?
|
||||
A: Certainly. You might want to change your tag delimiters from {} to something
|
||||
|
14
README
14
README
@@ -33,11 +33,15 @@ DESCRIPTION:
|
||||
|
||||
What is Smarty?
|
||||
|
||||
Smarty is a template engine for PHP. One of the unique aspects about
|
||||
Smarty that sets it apart from other templating solutions is that it
|
||||
converts the templates into native php scripts upon the first
|
||||
execution. After that, it just executes the compiled PHP scripts.
|
||||
Therefore, there is no costly template file parsing for each request.
|
||||
Smarty is a template engine for PHP. Many other template engines for PHP
|
||||
provide basic variable substitution and dynamic block functionality. Smarty
|
||||
takes a step further to be a "smart" template engine, adding features such
|
||||
as configuration files, template functions, and variable modifiers, and
|
||||
making all of this functionality as easy as possible to use for both
|
||||
programmers and template designers. Smarty also converts the templates into
|
||||
PHP scripts, eliminating the need to parse the templates on every
|
||||
invocation. This makes Smarty extremely scalable and managable for large
|
||||
application needs.
|
||||
|
||||
Some of Smarty's features:
|
||||
|
||||
|
Reference in New Issue
Block a user