Instead of:
> Action application/x-httpd-php-source "/php4/php.exe -s"
> AddType application/x-httpd-php-source .php4 .php .inc .htm
why not:
> Action application/x-httpd-php-source "/php4/php.exe
/path/to/showsource.php "
> AddType application/x-httpd-php-source .php4 .php .inc .htm
and using a php program that takes the input params and shows the
source for whatever file you're trying to look at?
I just pulled that out of my ass tho, dunno how viable it is as an idea
or a server directive, somebody out there correct me?
Gfunk - http://www.gfunk007.com/
I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.
----- Original Message -----
From: "Nold, Mark" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "'Lewis Bergman'" <[EMAIL PROTECTED]>; "Php-General (E-mail)"
<[EMAIL PROTECTED]>
Sent: Tuesday, January 23, 2001 3:49 PM
Subject: RE: [PHP] Turning off PHP for one directory with apache
> --------------------------------------------------------------------------
--
> -----------------
> Disclaimer: The information contained in this email is intended only for
the
> use of the person(s) to whom it is addressed and may be confidential or
> contain legally privileged information. If you are not the intended
> recipient you are hereby notified that any perusal, use, distribution,
> copying or disclosure is strictly prohibited. If you have received this
> email in error please immediately advise us by return email at
> [EMAIL PROTECTED] and delete the email document without making a
> copy.
> --------------------------------------------------------------------------
--
> -----------------
> You're right.
>
> Thats exactly what i wanted. If you imagine uploaded files, or attachments
> to email in a PHP mailing list archive. You definatly wouldnt want them to
> execute code, in the case of mailing list archives you'd probably want to
> display em.
>
> Would anybody know how i can conigure Apache (with PHP as a CGI) to then
> show these as PHP highlighted source?
>
> Ive tried (im using a windows box to test)
>
> Action application/x-httpd-php-source "/php4/php.exe -s"
> AddType application/x-httpd-php-source .php4 .php .inc .htm
>
> Any ideas what im doing wrong? (I do have a vague memory of someone say
you
> couldnt use this feature with PHP as a CGI)
>
> Or can someone confirm its definatly not available in PHP as a CGI?
>
> mn
>
>
>
>
> Mark Nold
> [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> Senior Consultant
>
> Change is inevitable, except from vending machines.
>
>
>
> -----Original Message-----
> From: Dan Lowe [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 23, 2001 12:42 PM
> To: Nold, Mark
> Cc: 'Lewis Bergman'; Php-General (E-mail)
> Subject: Re: [PHP] Turning off PHP for one directory with apache
>
>
> Previously, Nold, Mark said:
> >
> > After a bit of further playing it appears that simply AddType with the
> same
> > extensions that were set up should also stop php from working.
> >
> > So in a .htaccess file you can just
> > AddType text/plain .php4 .php .inc .htm
>
> Wouldn't that spit the source code out to the browser though? Personally
> I would find that undesirable.
>
> You could also do something like this, should work in an .htaccess or in
> the httpd.conf/access.conf files:
>
> # Stops .php .php3 .php4
> <Files ~ "^.*\.php?$">
> order allow,deny
> deny from all
> </Files>
> # Stops .inc
> <Files ~ "^.*\.inc$">
> order allow,deny
> deny from all
> </Files>
> # Stops .htm .html
> <Files ~ "^.*\.htm?$">
> order allow,deny
> deny from all
> </Files>
>
> -dan
>
> --
> Dan Lowe <[EMAIL PROTECTED]> http://tangledhelix.com/
>
> Can vegetarians eat animal crackers? -George Carlin
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]