Formatting.

This commit is contained in:
andrey
2001-12-04 20:56:47 +00:00
parent 63c1d1be8c
commit 5f22e1f756
3 changed files with 9 additions and 9 deletions

6
NEWS
View File

@@ -1,8 +1,6 @@
- added trusted_dir functionality, documented. (Monte)
- consolidated secure_dir tests to one function. (Monte)
- prepend SMARTY_DIR to default directories in class constructor. (Monte,
Ricard Pillosu)
- append _smarty_ to variable names in fetch() class function to avoid
- prepended _smarty_ to variable names in fetch() class function to avoid
namespace conflicts. (Monte)
- introduced $compile_id class variable that can be used to set persistent
compile identifier across multiple display calls, documented. (Andrei)
@@ -277,3 +275,5 @@ Version 1.0a
Version 1.0
------------
- initial release
/* vim: set et: */

View File

@@ -717,8 +717,8 @@ function _generate_debug_output() {
Function: _is_trusted()
Purpose: determines if a template is within the trusted_dir or not.
\*======================================================================*/
function _is_trusted($resource_type, $resource_name) {
function _is_trusted($resource_type, $resource_name)
{
$_smarty_trusted = false;
if (!empty($this->trusted_dir)) {
// see if template file is within a trusted directory. If so,
@@ -726,7 +726,7 @@ function _is_trusted($resource_type, $resource_name) {
if ($resource_type == 'file') {
if (is_readable ($this->trusted_dir)) {
if (substr(realpath($resource_name),0, strlen(realpath($this->trusted_dir))) == realpath($this->trusted_dir)) {
if (substr(realpath($resource_name), 0, strlen(realpath($this->trusted_dir))) == realpath($this->trusted_dir)) {
$_smarty_trusted = true;
}
}

View File

@@ -717,8 +717,8 @@ function _generate_debug_output() {
Function: _is_trusted()
Purpose: determines if a template is within the trusted_dir or not.
\*======================================================================*/
function _is_trusted($resource_type, $resource_name) {
function _is_trusted($resource_type, $resource_name)
{
$_smarty_trusted = false;
if (!empty($this->trusted_dir)) {
// see if template file is within a trusted directory. If so,
@@ -726,7 +726,7 @@ function _is_trusted($resource_type, $resource_name) {
if ($resource_type == 'file') {
if (is_readable ($this->trusted_dir)) {
if (substr(realpath($resource_name),0, strlen(realpath($this->trusted_dir))) == realpath($this->trusted_dir)) {
if (substr(realpath($resource_name), 0, strlen(realpath($this->trusted_dir))) == realpath($this->trusted_dir)) {
$_smarty_trusted = true;
}
}