Re: Base-Templates Dir Feature Added to Smarty1.4.0
| From: | Cynic | Date: | Thu, 10 May 2001 12:07:19 +0000 |
| Subject: | Re: Base-Templates Dir Feature Added to Smarty1.4.0 | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-718@lists.php.net to get a copy of this message | ||
No, it works like this (and it's quite simple to grasp, just
read the Smarty constructor):
With register_globals on, you can just use
var $global_assign = array( 'SCRIPT_NAME' , 'PHP_SELF' ) ;
but with register_globals off, these are unset, so you
need
var $global_assign = array( 'HTTP_SERVER_VARS' =>
array( 'SCRIPT_NAME' ,
'PHP_SELF' )
);
the second version works in both settings, since track_vars
is always on.
in other words:
with register_globals on, you can assign global variables OR
HTTP_*_VARS members, but only HTTP_*_VARS members with
register_globals off
there's no magic in it.
At 13:38 10.5. 2001, Mirko Buffoni wrote the following:
--------------------------------------------------------------
>>Yeah, I noticed, it's not clear from the example.
>>
>>According to the docs
>>(http://www.phpinsider.com/php/code/Smarty/docs/c87.htm#SETTING.GLOBAL.ASSI
>GN),
>>it should be:
>>
>> array( 'HTTP_SERVER_VARS' => array( 'SCRIPT_NAME' ),
>> 'PHP_SELF' );
>
>Much clearer, now! It works indeed. Thanks!!!!
>
>Mirko
>
>---
>You are currently subscribed to smarty as: cynic@mail.cz
>To unsubscribe send a blank email to $subst('Email.Unsub')
>Visit Smarty's homepage at
>http://www.phpinsider.com/php/code/Smarty/
------end of quote------
cynic@mail.cz
-------------
And the eyes of them both were opened and they saw that their files
were world readable and writable, so they chmoded 600 their files.
- Book of Installation chapt 3 sec 7