Page 1 of 1

PHP Being Ignored Selectively

PostPosted: 14. February 2010 00:25
by serenayl
PHP on my test pages is being ignored. I store my site in xampp/htdocs/. Pages are showing up fine, except for anything in <? ?> is just simply ignored.

So for example, if after the header I have this:

<body>
<?php
include('blargles.php');
echo ('is php working at all?');
?>
blahblah
</body>

the only thing that will show up is the "blahblah" part. I am not attempting to just open these files, I am navigating to them through localhost.

Whether the include is a real document or not, nothing happens. For a while yesterday, I was able to get it to throw an error if the include was bogus (in this situation, the a valid include file would still not execute), but am not currently able to replicate that situation. It started doing that yesterday after I visited the xampp/htdocs/xampp page and checked PHP's status, but doing the same thing today does not work.

My installation of XAMPP looks successful (localhost used to take me to the splash page, now takes me to xampp/htdocs/xampp). Since this page seems to be in perfect working order and everything in this directory is PHP, it looks like the PHP install should be okay. The status says PHP is activated, and phpinfo() is working just fine. Moving my sites from xampp/htdocs to xampp/htdocs/xampp is not successful either.

I'm stumped and 2 days scouring the internet has gotten me nowhere. I would really appreciate the help if I can get it.

Thanks :).

Re: PHP Being Ignored Selectively

PostPosted: 14. February 2010 11:30
by Wiedmann
So for example, if after the header I have this:
Code: Select all
<body>
<?php
include('blargles.php');
echo (
'is php working at all?');
?>
blahblah
</body>

"after the header".... so that's not the complete testscript?


the only thing that will show up is the "blahblah" part.

- name/location of this file in the filesystem
- the uri you are using to request this file with your browser
- the entry in the access/error.log from this request.