Why should we always put our html-code (that contains smarty tags) to a temporary file for smarty use ? It can be done without doing so. This is important in the case of executing templates that come from DB, LDAP, etc. See this link to know details:
Hope you will enjoy !!