Re: Referencing Directives

2002-05-29 Thread Ian D. Stewart

On 2002.05.28 01:23 Per Einar Ellefsen wrote:

 
 Or... maybe you could try using Apache class methods inside Perl 
 sections (like document_root) -- however I think that'd be pretty 
 shaky.

Hmm...something to tinker with as time permits...


Thanx,
Ian



Referencing Directives

2002-05-27 Thread Ian D. Stewart

Is it possible to reference the value of one Directive within another 
Directive (e.g., PerlSetVar VariableName ${DocumentRoot}/subdir) ?


Thanx,
Ian



Re: Referencing Directives

2002-05-27 Thread Per Einar Ellefsen

At 21:13 27.05.2002, Ian D. Stewart wrote:
Is it possible to reference the value of one Directive within another 
Directive (e.g., PerlSetVar VariableName ${DocumentRoot}/subdir) ?

If you use Perl sections, yes.

Perl
$DocumentRoot = '/home/httpd/htdocs';
push @PerlSetVar, [ VariableName = $DocumentRoot/subdir];
/Perl

Note that you need to set $DocumentRoot in a Perl section as well.

You might want to look at mod_macro too.


-- 
Per Einar Ellefsen
[EMAIL PROTECTED]





Re: Referencing Directives

2002-05-27 Thread Ian D. Stewart

On 2002.05.27 15:39 Per Einar Ellefsen wrote:
 At 21:13 27.05.2002, Ian D. Stewart wrote:
 Is it possible to reference the value of one Directive within 
 another Directive (e.g., PerlSetVar VariableName 
 ${DocumentRoot}/subdir) ?
 
 If you use Perl sections, yes.
 
 Perl
 $DocumentRoot = '/home/httpd/htdocs';
 push PerlSetVar, [ VariableName = $DocumentRoot/subdir];
 /Perl

Thanx Per.  I thought of something like that after I sent out the 
message, though wasn't sure of the syntax.

 
 Note that you need to set $DocumentRoot in a Perl section as well.

So Directives declared outside the Perl section (e.g., ServerRoot, 
DocumentRoot, etc) are not accessible within the Perl section?

 
 You might want to look at mod_macro too.

Will do.


Thanx,
Ian