You might try: AddType application/x-httpd-php .php (assuming your php files are named [whatever].php) instead of the SetHandler. I would also put SetHandler default-handler in there so mod_perl doesn't try to run stuff. I checked the config of a site where PHP runs under scoop, and that's (mostly) how it's set up. The only other difference is that site runs the php through a proxy apache before requests even get to the scoop handling mod_perl apache. I don't know if that will make a difference or not, but my guess is the AddType above, combined with default-handler will do it for you. --R On Fri, 2006-08-25 at 15:07 -0400, Maxime Romano wrote: > Hi everyone, > > I'm trying to install some PHP application on my server under Scoop's > tree, such that scoop resides at http://www.example.com/ and the PHP > scripts at http://www.example.com/php/. > > So, the solution I've found so far is to stick all the PHP scripts under > $scoopdir/html/php/, then add the following to my httpd.conf: > > <Location /php> > SetHandler application/x-httpd-php > </Location> > > This works, but has the (serious) drawback of making the PHP interpreter > parse every file. Now, this isn't particularly tragic, but then every > file under http://www.example.com/php/ gets sent with a "text/html" > content-type, which is terrible, because then images don't get sent > right, and nor do CSS files get accepted. So, in trying to give CSS > files the proper content-type, I've attempted many different > combinations of AddHandler, RemoveHandler and AddType for the last few > hours. There are generally only two outcomes: either I put SetHandler > application/x-httpd-php in and everything gets interpreted as PHP, or I > don't and nothing gets interpreted (which is obviously incorrect). > > Now, the scoop install itself is running on a Virtual Server on an > apache site which hosts many other PHP-based sites without any problem > or special httpd.conf settings whatsoever. So it's not PHP's fault. > Furthermore, scoop has been in use for the longest time, and I'm > convinced that the mod_perl is properly installed and configured, as > well. So it's not scoop's fault either. > > The culprit seems to be me :) > > So, either I'm doing it completely wrong, or maybe it's impossible, or > maybe my strategy is just bad. Anyway, if anyone knows anything about > this and could shed some light on my predicament, I would be immensely > grateful. > > - Max > > This is the relevant portion of my httpd.conf : > > <VirtualHost 10.10.10.10> > ServerAlias www.example.com > ServerName www.example.com > DocumentRoot /home/example/scoop/html > > User example > Group example > > <perl> > use lib qw( /home/example/scoop/lib ); > </perl> > > PerlModule ModPerl::Test > <Location /> > SetHandler perl-script > PerlSetVar DBType mySQL > PerlSetVar mysql_version 4.0 > PerlSetVar db_name example > PerlSetVar db_host localhost > PerlSetVar db_user example > PerlSetVar db_pass hackme > <perl> > my $vfile = '/home/example/scoop/VERSION'; > my $v = do $vfile; > push(@{ $Location{'/'}->{PerlSetVar} }, > [ scoop_version => $v->{Version} ], > [ scoop_date => $v->{Date} ], > [ scoop_revision => $v->{Revision} ], > [ scoop_author => $v->{Author} ], > [ scoop_state => $v->{State} ] > ); > </perl> > PerlSetVar cookie_host .example.com > PerlSetVar SMTP localhost > PerlSetVar site_id example > PerlSetVar site_key hackmehackmehackme > PerlSetVar dbdown_page /pages/dbdown.html > PerlRequire /home/example/scoop/etc/startup.pl > PerlHandler Scoop::ApacheHandler > # PerlSendHeader On > </Location> > > <Location /images> > SetHandler default-handler > </Location> > > <Location /pages> > SetHandler default-handler > </Location>k > > <Location /php> > SetHandler application/x-httpd-php > </Location> > > <Location ~ "^/(robots\.txt|favicon\.ico)$"> > SetHandler default-handler > </Location> > Alias /files/ /home/example/scoop/files/ > Alias /adminfiles/ /home/example/scoop/adminfiles/ > ErrorDocument 404 /pages/404.html > ErrorDocument 500 /pages/500.html > #Alias /wiki /home/example/scoop/wiki/index.php > #Alias /index.php /home/example/scoop/wiki/index.php > > </VirtualHost> > > Apache version is 1.3.37 on Fedora Core 2 > > > _______________________________________________ > Scoop-help mailing list > Scoop-help at lists.kuro5hin.org > http://lists.kuro5hin.org/mailman/listinfo/scoop-help