edropus Posted June 8, 2008 Share Posted June 8, 2008 Hi, this is my first day trying to use PHP. I'm setting up Apache server 2.2x (latest build) and have downloaded PHP, and followed some manual setup steps as the automatic setup was not recommended. Here is, more or less, what I have done: 1) Download Apache 2.2x and install to standard directory 2) Download PHP binary zip and install in C:\php with extensions in C:\php\ext 3) Add the following to the http.config in Apache's config folder: Loadfile "C:/PHP/php5ts.dll" LoadModule php5_module "C:/PHP/php5apache2_2.dll" PHPIniDir "C:/PHP/" AddHandler application/x-httpd-php .php AddHandler application/x-httpd-php-source .phps 4) Add C:\PHP to Environmental Variables 5) Restart the computer When I start Apache and look at the error log it says: "[sun Jun 08 16:17:50 2008] [notice] Apache/2.2.8 (Win32) PHP/5.2.6 configured -- resuming normal operations" Which I think is a good thing? I feel like I'm missing a step here. When I run, like, test.html, which basically just says: <html> Testing PHP: <?php echo "test taco test test"; ?> "Testing" comes up, but the echo isn't tossing anything out there. What am I doing wrong? I feel like there's a huge obvious step I'm missing here, like running an exe to launch PHP or something. Any suggestions would be appreciated. I'm in way over my head here. Thanks! Quote Link to comment https://forums.phpfreaks.com/topic/109308-apache-22x-setup-noob/ Share on other sites More sharing options...
wildteen88 Posted June 9, 2008 Share Posted June 9, 2008 You need to save your file with the .php file extension not .html Also ensure you saving your php files in Apache'ss htdocs folder (eg C:/[path/to/Apache]/htdocs) and that you are going to http://localhost to run your scripts. You cannot load PHP files directly in to your web browser like you can with HTML files. Quote Link to comment https://forums.phpfreaks.com/topic/109308-apache-22x-setup-noob/#findComment-561313 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.