ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a Red Hat 9 box that I have recently setup. I am having a problem with PHP scripts. I recently setup IP Table Logger and everything is setup correctly and working with the exception of the the web part. I have PHP 4.2.2 Installed and at a command prompt where my php executable is I can type in "php -i" and I receive the html information page . However all of the PHP scripts for the iptable logger do not work. I already had to change the cgi.force.redirect in th php.ini file and that got me to an error that said "Premature end of script headers". Now the funny thing is that if I had the following line to the beginning of the script it will work for the text part of the html page, but not the graphics or pics.
#!/usr/bin/php
I have added
LoadModule php4_module modules/libphp4.so
&
DirectoryIndex index.php
&
application/x-httpd-php php
to my httpd.conf to no avail
Even with this added I can specify a path and it still doesn't detect the index.php file that I have. It just tels me that permission is denied for that directoy. However, I have apache running as the user apache and I made apache the owner of all files in /var/www/
Any insight or ideas would be greatly appreciated.
Sorry, no answer from me, as I am having a very similar problem: Currently unable to open any local PHP files running on apache.... (html files are served just fine)
If you (or anyone else) finds a solution to this, please le me know too: post reply here.
It has something to do with the permissions I think. All I did to get around the problem was move my PHP served pages into the /usr/share/web folder that I created and all php is now served fine. I never really had the time to research it as I needed the site up and running ASAP. Have fun !
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.