mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-06 19:34:27 +02:00
Correct default template handler function example.
This commit is contained in:
@@ -217,8 +217,8 @@ function make_template ($resource_type, $resource_name, &$template_source, &$tem
|
||||
if ( ! is_readable ( $resource_name )) {
|
||||
// create the template file, return contents.
|
||||
$template_source = "This is a new template.";
|
||||
$template_timestamp = time();
|
||||
$smarty_obj->_write_file($resource_name,$template_source);
|
||||
require_once SMARTY_CORE_DIR . 'core.write_file.php';
|
||||
smarty_core_write_file( array( 'filename'=>$smarty_obj->template_dir . DIRECTORY_SEPARATOR . $resource_name, 'contents'=>$template_source ), $smarty_obj );
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user