WAMP - How to install and setup Apache, MySQL and PHP in Windows
This tutorial will walk you every single step of the way through installing and setting up WAMP (Windows, Apache, MySQL & PHP). With WAMP installed, you can run a web server (and things like WordPress, MediaWiki, and Jinzora) on your Windows PC.
- To get started, head over to the WAMP download page and save the .exe to your desktop. Once the download has completed, run the installation file. The first message you’ll see is a warning – if you have an older version of WAMP (1.x) installed, make sure to uninstall it first. Otherwise click Yes to continue.
- Click Next on the initial setup screen.
- Review the License Agreement, select I accept the agreement and then click the Next button.
- It’s a good idea to leave the default installation directory alone (C:\wamp\) – but if you want to change it, now’s the time. Click Next to continue.
- Decide if you want to have WAMP Quick Launch and/or Desktop icons, and click Next.
- Finally, click Install.
- The installation doesn’t take too long.
- Once it has completed, the setup phrase will begin. If you have Firefox set as your default browser, WAMP will ask you if that’s the browser you want to use. Click Yes.
- At this point, if you have a software Firewall installed, it will probably pop up and warn you that Apache wants to accept incoming connections. Depending on your specific Firewall the “button” to click may be different, but it will be something similar to Unblock. Do not click “Keep Blocking”.
- Leave the SMTP: server set as localhost (more on this later) but do change the email address to yours. Click Next.
- That’s it – you’re done! Make sure that there’s a check in the Launch WampServer 2 now box, and click Finish.
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
click to enlarge
- In your System Tray you should now see a “WAMP” icon. Click it, and select Put Online (Note: if it says Put Offline ignore this step and skip to the next one).
- Open your browser (if it isn’t already) and enter the URL http://localhost.
- The WAMP configuration page will load. From here you can access the tools phpMyAdmin, sqlitemanager etc.
- Now you’ll want to set a MySQL password, because by default, WAMP doesn’t set one. Select phpMyAdmin from the WAMP configuration page. At the bottom of the phpMyAdmin screen you’ll see a message about MySQL running without a root password.
- To correct this, select the Privileges link. In the User overview section, place a check in the box next to Root – Localhost (see image below) and then click the Edit Privileges button.
click to enlarge - Scroll down to the Change password section, and enter your password in both boxes. Click Go to save the change.
- Make sure you get a message saying The password for 'root'@'localhost' was changed successfully.
- Minimize your browser window, and open up Windows Explorer (or whatever file manager you use in Windows). Navigate to the C:\wamp\apps\phpmyadminx.x.x\ folder. Inside that folder, open up config.inc.php – ideally in an HTML or PHP editor, but Notepad will do if you don’t have an html/php/code editor.
- Search for the line $cfg['blowfish_secret'] = ''; – if you’re using notepad it might be easier to just search for the word blowfish
- Change the line $cfg['blowfish_secret'] = ''; to $cfg['blowfish_secret'] = 'mypassphrase'; – where mypassphrase is your own password – not the same one you specified for root in MySQL.image: http://www.simplehelp.net/images/wamp/wamp08.png
Note: as you can see from the screenshots above and below, this is much easier to work with in an HTML/PHP editor than it is in Notepad. - Now search for the phrase ['auth_type'] = 'config'; (again, if you’re using Notepad you might want to just search for auth_type).
- Change config to cookie.
- Almost done. Now search for $cfg['Servers'][$i]['password'] = ''; Replace the = ''; with = 'your-mysql-password'; – where your-mysql-password is the MySQL password you specified back in step #6 of this section.
- Save the changes you’ve made and exit out of your editor. Click on the WAMP icon in your System Tray and select Restart All Services.
- Bring up your browser again, and refresh http://localhost. Select phpmyadmin again.
- This time you’ll be prompted to login. Use root as the Username and enter the password you specified in step #6 as the password. Ignore the error about mcrytp not being loaded – we’ll fix that in a minute.
- Return to the Privileges section, and this time place a check next to the user root with the host 127.0.0.1 (see screenshot below) and click the Edit Privileges button.
- Set the password to the same one you used for root previously (step #6) and click Go. Confirm the password was updated.
- Now select the user root in the production.mysql.com host section, and once again click the Edit Privileges button.
- Again set the password to the same one you’ve previously used for root.
- And make sure it updates successfully.
- Click the WAMP icon in your System Tray, choose PHP from the menu, then PHP extensions, scroll down to php_mcrypt and select it.
- Refresh phpMyAdmin in your browser, and this time you’ll be prompted to login, but without the mcrypt error.
- You’ve now set a password for MySQL, making it considerably more secure.
image: http://www.simplehelp.net/images/wamp/wamp00.png
image: http://www.simplehelp.net/images/wamp/wamp01.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp02.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp05.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp07.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp09.png
image: http://www.simplehelp.net/images/wamp/wamp10.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp12.png
image: http://www.simplehelp.net/images/wamp/wamp13.png
image: http://www.simplehelp.net/images/wamp/wamp14.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp15.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp17.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/wamp19.png
click to enlarge
- If you’re running Windows XP, 2000 or NT and have an outgoing (SMTP) mail server already installed on your PC, and can be accessed by localhost, you can skip all the steps in this section – your’e done! If you’re using Vista (or don’t have a mail server installed) – keep reading.
- Because a number of services you may use require a working mail server, we’ll set up Fake Sendmail and use your ISPs outgoing mail server. An example of a service that requires working mail is WordPress – if you forget your password and want to reset it, WordPress will email it to you. Without Fake Sendmail (or a local SMTP server) every time a service tries to send an email, it will fail.
- Head over to http://glob.com.au/sendmail/ and download sendmail.zip. If your ISP requires that you use SSL, make sure to download sendmail-SSL.zip as well. Create the folder(s) C:\usr\lib\ and extract sendmail.zip (and sendmail-SSL.zip if you need it) into that folder.
- Open up sendmail.ini in Notepad. Scroll down to the smtp_server= section and change it to smtp_server=your.smtp.server, where your.smtp.server is your ISPs outgoing mail (SMTP) server. If you’re unsure of your outgoing mail server, you can try this list of ISP mail servers – if yours isn’t listed there, check w/ your ISP. In the smtp_port= section, make sure it’s set to 25 – assuming your ISP uses port 25 for SMTP (not all do – though mine does).
- In the default_domain= section, add your ISPs domain. For example, if you use Comcast as your ISP, add comcast.net. Because I have service from Telus, my default domain is telus.net (as seen in the screenshot below).
- If your SMTP server requires authentication, add your username to the end of the auth_username= field, and your password to the auth_password= field.Note: you can use the Gmail SMTP server (see this FAQ for details) – assuming you have a Gmail account. However, during testing I noticed a considerable delay in receiving mail – up to 7 hours. Using my ISPs mail server settings there was no delay at all.
- Save your changes to the file (sendmail.ini) and exit Notepad. Now click the WAMP icon in your System Tray, select PHP and then click php.ini.
- Scroll down to the [ mail function ] section. Comment out each of the For Win 32 lines by adding a semicolon ( ; ) in front of each one (see screenshot below). Uncomment the line sendmail_path = by removing the semicolon ( ; ) in front of it. Add "/usr/lib/sendmail.exe -t" to the end of the line, so that it reads: sendmail_path = "/usr/lib/sendmail.exe -t" (again, see the screenshot below).
- Save php.ini and exit out of Notepad (or whatever editor you used to edit php.ini). Click on the WAMP icon in your System Tray and select Restart All Services.
- Now any time one of your web services needs to send an email…
- it will go through!
- That’s it – you’re done! You now have a fully functional Apache, MySQL and PHP system on your PC.
click to enlarge
click to enlarge
click to enlarge
click to enlarge
image: http://www.simplehelp.net/images/wamp/fsm04.png
click to enlarge
image: http://www.simplehelp.net/images/wamp/fsm07.png
image: http://www.simplehelp.net/images/wamp/fsm08.png
image: http://www.simplehelp.net/images/wamp/fsm09.png
Read more at http://www.simplehelp.net/2008/08/25/how-to-install-and-setup-apache-mysql-and-php-in-windows/#3yPyL4desistOcez.99
Source : http://www.simplehelp.net/2008/08/25/how-to-install-and-setup-apache-mysql-and-php-in-windows/
No comments