once i have installed php on my pc and i try to test it by making a php file that has in it
<?php phpinfo(); ?>
all it does is display the source of the file:mad:
Did you put the file somewhere with the webserver's web document root directory tree? If so, did you launch it from your browser via a url like "http://localhost/filename.php" (rather than double-clicking the file or using the File->Open menu option)?
oh sorry i should have said that yea i did do that i went into firefox and typed localhost/test.php
I'm going to move this to the Install forum and let the installation gurus help you out (I hope).
ok thanks
What web server are you using, and what instructions did you follow to configure the web server to serve .php files as PHP scripts?
im using apache 2.2 and i used a youtube video: http://youtube.com/watch?v=zviH3QyLSZ0
Okay, double check the Apache configuration file (httpd.conf) to see if you can find:
AddType application/x-httpd-php .php
If it is not present, add that line, save httpd.conf and restart the web server.
i checked the conf file and that line is there
#BEGIN PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL PHPIniDir "C:/Program Files/PHP/" LoadModule php5_module "C:/Program Files/PHP/php5apache2_2.dll" AddType application/x-httpd-php .php AddType application/x-httpd-php-source .phps #END PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL