f



SSI Including PHP File Within PHP File Causes Seg Fault and Crash

Can somebody concur or verify the following?  I'm having this problem on all
of my installations.

I've got Apache 2.0.40 and PHP 4.2.2 installed and configured from RedHat
RPMs.  Nothing out of the ordinary.  In the httpd.conf file, PHP files are
called with the following:

<Files *.php>
    SetOutputFilter PHP;INCLUDES
    SetInputFilter PHP
    LimitRequestBody 524288
</Files>

I create two files as follows:

/test1.php
<!--#include virtaul="/test2.php" -->

and

/test2.php
Testing 1 2 3

By going to http://host/test1.php, it may or may not display the file
contents of test2.php.  Usually (9/10 times) I get a seg fault in the error
log.  If I change the filename of test.php to test.html and include that, it
works fine.  I've tried this on various versions of both Apache and PHP up
to the most recent CVS versions and still get the same results.

If somebody can help me out or concur my problem, I would much appreciate
it.

Arthur


0
2/12/2004 2:32:20 AM
comp.lang.php 32646 articles. 0 followers. Post Follow

1 Replies
1639 Views

Similar Articles

[PageSpeed] 42

don't try to treat a .php file as an .shtml just do this

<?php
  include("test2.php");
?>

--
Mike Bradley
http://www.gzentools.com  -- free online php tools
"Arthur M. Kang" <arthur@levelogic.com> wrote in message
news:UABWb.39235$QJ3.24102@fed1read04...
> Can somebody concur or verify the following?  I'm having this problem on
all
> of my installations.
>
> I've got Apache 2.0.40 and PHP 4.2.2 installed and configured from RedHat
> RPMs.  Nothing out of the ordinary.  In the httpd.conf file, PHP files are
> called with the following:
>
> <Files *.php>
>     SetOutputFilter PHP;INCLUDES
>     SetInputFilter PHP
>     LimitRequestBody 524288
> </Files>
>
> I create two files as follows:
>
> /test1.php
> <!--#include virtaul="/test2.php" -->
>
> and
>
> /test2.php
> Testing 1 2 3
>
> By going to http://host/test1.php, it may or may not display the file
> contents of test2.php.  Usually (9/10 times) I get a seg fault in the
error
> log.  If I change the filename of test.php to test.html and include that,
it
> works fine.  I've tried this on various versions of both Apache and PHP up
> to the most recent CVS versions and still get the same results.
>
> If somebody can help me out or concur my problem, I would much appreciate
> it.
>
> Arthur
>
>


0
me1383 (446)
2/12/2004 3:31:46 AM
Reply: