Slackware and PHP
Hi guys ! :)
Well, i have a problem with PHP,, i just started learning the PHP script, i installed slackware 10.1 (recently bought the CDs from the slackware store to support this great distro :) ), and started the MySQL database server (that was kinda easy), but (yeah, big monster BUT), when i typed the script to test the PHP installation and then opened in the web browser, nothing happened. :confused: Wonder if the PHP is correctly installed :confused: I read the php manual, but i didn't understand it, because the PHP that cames with slack 10.1 is already installed, i tested the script but it only displays the script without the <? php .... ?> tags Wonder if i'm doing something wrong, or does php is not initialized. Here are my script.... ------------- Script phpinfo() ------------------ <?php phpinfo(); ?> ----------------------------------------------------- Well i will continue reading to see what i'm doing wrong. :study: |
Edit /etc/apache/httpd.conf and uncomment this line near the bottom :
Include /etc/apache/mod_php.conf You may want to edit the DirectoryIndex line as well like : DirectoryIndex index.html index.php index.htm index.xhtml |
Did you access it via apache? Can you see a request being made in the access_log?
|
ok, i edited those lines in the httpd.conf, but nothing happened. :(
Access via apache ?? How ?? |
Restart apache:
/etc/rc.d/rc.httpd restart Then point your browser to the php script. |
Quote:
|
well just stick
<?php phpinfo(); ?> in a file called ... test.php, and stick it in /var/www/htdocs/ restart apache apachectl restart and access it via http://localhost/test.php If it doesn't work, then you can see why in the apache logs /var/log/apache/error_log |
Thanks guys, you helped me a lot, i solved the problem, i just chenged the directory in the line of DirectoryRoot to the directory that has the PhP scripts that i'm programming (i'm just starting with PhP).
Well guys, thanks a lot, take care. |
All times are GMT -5. The time now is 12:40 PM. |