learn_how_to_install_apache.docx

Upload: suhaibah-idris

Post on 14-Apr-2018

215 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    1/8

    Installing Apache:

    Today we will be installing Apache version 2.2.4. Follow the steps carefully.

    1. Double click "apache_2.2.4-win32-x86-no_ssl.msi", and if prompted, click "run".

    2. An installation wizard will appear:

    Click "Next".

    3. The next page contains the terms of agreement. Select "I accept", and click "Next".

    4. Read about the Apache Server, and click "Next"

    5. The next screen will ask you for specific server information. Enter the values seen below:

    6. Set your Destination. We have two choice to set destination

    a) Inside program file- When you install n save your installation inside program, when you want to renew or change any

    File, we will have problem. This is because, our computer can detect any process and before weDo some editing n save our work, error will come out and want you to ask administrator forPermission to do that.

    b) Outside program file

    - For example : c:\apache software foundation\apache2.2. This will be safe n good because outsideprogram file its free to install anything.

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    2/8

    Click "Next".

    7. On the next screen, select "Typical Installation" and click "Next".

    8. Click "Next".

    9. Make sure the folder name is apache2.

    10. Click "Install".

    11. Open up Internet Explorer and type in "http://localhost". If you see a page that says "It works!" then the Apache serv

    has been installed successfully.

    Apache configuration

    i. Add the following line in the LoadModule field.LoadModule php5_module c:/php5/php5apache2_2.dll

    ii. Look for this syntax

    DirectoryIndex index.html

    And edit it as below

    DirectoryIndex index.php index.html

    iii. Look for this moduleAnd, add the following before the clause

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    3/8

    AddType application/x-httpd-php .php

    iv. At the end of httpd.conf file add the following.PHPIniDir "c:/windows"

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    4/8

    Installing PHP:

    Next we will be installing PHP version 5. Follow the steps carefully.

    1. Create a new folder called "php5" in your C Drive. Copy the "php-5.2.0-Win32.zip" file to there ("C:\php5") and extra

    using WinZIP or a similiar program.

    2. Your C:/php5/directory should now look like:

    3. Next copy the "php.ini-dist" file from "C:/php5/" to "C:/WINDOWS" and rename it to "php.ini". This is your PHPconfiguration file. We'll come back to this later.

    4. **** In your"htdocs"directory, create a file called "info.php". Open it in notepad and add this line of code to it:

    5. Restart your Apache Server for the changes to take effect: Start > All Programs > Apache HTTP Server 4.2.4 > Con

    Apache Server > Restart

    6. Open up Internet Explorer and type in: http://localhost/info.php. If your browser takes you to a page that looks like ththen PHP has been installed successfully!

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    5/8

    Modifying your PHP Configuration File:

    Your PHP configuration (php.ini) file is located in "C:/WINDOWS/php.ini". You can modify it with notepad or a similiatext editor.

    Find the doc_root=

    Change it to

    doc_root = "c:\apache2\htdocs"

    Open it up and find the line that says:

    extension_dir = "./"

    and change it to

    extension_dir = "C:\php5\ext"

    Find the line that says:

    ;session.save_path = "/tmp"

    and change it to

    session.save_path = "C:\WINDOWS\temp"

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    6/8

    Installing MYSQL:

    Next we will be installing MySQL version 5. Follow the steps carefully.

    1. Go to www.mysql.com and download the "Windows (x86) ZIP/Setup.EXE (version 5.0.27)" to your desktop. (To do t

    you'll need to register an account with MySQL.)

    2. Once "mysql-5.0.27-win32.zip" has finished downloading, you can extract it using WinZIP or a similiar program.

    3. Once extracted, double click on the "Setup.exe" file. An installation wizard will appear.

    Click "Next".

    4. Select "Typical" Installation and click "Next".

    5. Click "Install"

    6. The next screen will ask you to "Sign Up". Select "Skip Sign-Up" for now.

    7. The next screen will tell you that the installation wizard is complete. Make sure that the "Configure the MySQL Servnow" field is checked before clicking "Finish".

    http://dev.mysql.com/downloads/mysql/5.0.html#downloadshttp://dev.mysql.com/downloads/mysql/5.0.html#downloads
  • 7/27/2019 Learn_how_to_Install_Apache.docx

    7/8

    8. The MySQL Server Instance Configuration Wizard should appear. Click "Next".

    9. Select "Detailed Configuration" and click "Next".

    10. Select "Developer Machine" and click "Next".

    11. Select "Multifunctional Database" and click "Next".

    12. Click "Next".

    13. Select "Decision Support (DSS)/OLAP" and click "Next".

    14. Select "Multifunctional Database" and click "Next".

    15. Make sure "Enable TCP/IP Networking" is checked, the Port Number is set to "3306", and "Enable Strict Mode" ischecked. Click "Next".

    16. Select "Standard Character Set" and click "Next".

    17. Check "Install As Windows Service", set the Service Name to "MySQL", and check "Launch the MySQL Serverautomatically". Make sure that the "Include Bin Directory in Windows Path" is NOT checked. Click "Next".

    18. On the next screen, check the box that says "Modify Security Settings". Enter a password for the default "root"account, and confirm the password in the box below. Do NOT check the boxes "Enable root access from remote

    machines" or "Create An Anonymous Account". Click "Next".

    19. Click "Execute". (This may take a few minutes. Be patient).

    20. Click "Finish".

  • 7/27/2019 Learn_how_to_Install_Apache.docx

    8/8