]> git.mxchange.org Git - mailer.git/blobdiff - inc/functions.php
Some improvements, caching of email templates prepared
[mailer.git] / inc / functions.php
index 7838ec88620947b87d2cc7c6bb17e64386358bf7..f9a51c0cb6e0006883b0a6450a1e28d0fe1bf620 100644 (file)
@@ -3876,11 +3876,16 @@ function generateMetaDescriptionCode () {
 }
 
 // Generates an FQFN for template cache from the given template name
-function generateCacheFqfn ($template) {
+function generateCacheFqfn ($template, $mode = 'html') {
        // Is this cached?
        if (!isset($GLOBALS['template_cache_fqfn'][$template])) {
                // Generate the FQFN
-               $GLOBALS['template_cache_fqfn'][$template] = sprintf("%s_compiled/html/%s.tpl.cache", getConfig('CACHE_PATH'), $template);
+               $GLOBALS['template_cache_fqfn'][$template] = sprintf(
+                       "%s_compiled/%s/%s.tpl.cache",
+                       getConfig('CACHE_PATH'),
+                       $mode,
+                       $template
+               );
        } // END - if
 
        // Return it