Jump to content

Recommended Posts

Hi i am a complete noob when it comes to this.

 

I installed apache web server the latest version 2.2.6, and latest php 5.2.0rc4.

 

Apache runs fine but i cant get my php files to show properly they come up as code and dont execute?

 

What ive done so far to the httpd.conf is

 

    LoadModule php5_module "C:/PHP/php5apache2_2.dll

    AddType application/x-httpd-php .php

    AddType application/x-httpd-php-source .phps

 

And i created the php file in notepad and renamed it to a php file(The extension)

 

the page comes up as code the code is:

 

<?php

phpinfo();

?>

 

Any help would be most welcome as i have to make a pagr for my diertation and still need to get mysql working lol.

 

Thank you all for your time :D

Link to comment
https://forums.phpfreaks.com/topic/75027-apache-php-and-mysql/
Share on other sites

Those configuration lines are correct. Did you restart Apache after modifying the httpd.conf. Also when creating php files in notepad make sure you select All Files from the File Type drop down box when you goto File > Save As... (That will stop Notepad from add .txt to the end of the file name.

 

When you go to run your script make sure you are going to http://localhost/ and not opening the php script directly into your browser, via File > Open or Open With within windows explorer.

 

Also PHP5.2.0rc4 is out of date. PHP5.2 has now been release and the latest version is PHP5.2.4

Link to comment
https://forums.phpfreaks.com/topic/75027-apache-php-and-mysql/#findComment-379757
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.