There are times when we are so anxious to jump into creating
something new that we forget to cover the basics. For web developers it
is important, actually vital, to have the ability to test your projects
locally before they go live.
While much of the web relies on a Linux, Apache, MySQL, PHP stack, or LAMP, to power applications and dynamic websites, not everyone codes in a Linux environment.
Those who prefer Windows can still replicate how their code will work by using WAMP to replicate a live web environment right on their own computer with the only difference being substituting the Linux operating system in the stack for Windows.
When you click next you will be asked to accept the license agreement. Since it is a GPL license you are free to do just about anything with it so you can go ahead and accept.
The next step requires you to select the folder where you would like to install your WAMP server. The default will be c:\wamp however you can change this to install the server into any directory or partition you choose.
After you choose your directory you will have the option to setup icons. Once you decide on this click Next and then confirm the installation settings again by clicking Install.
Once the installation runs its course you will be asked to choose your default browser. Internet Explorer is the default choice but you can navigate your way to any other browser of your choosing.
NB – if your Windows firewall pops up at this point make sure to grant Apache access.
The next decision you will have to make is to set the PHP mail parameters. Many people leave this set to the defaults when setting up a testing server on their local computer. If you wish to configure it to connect to your SMTP server you may do so here but unless you plan on testing email capabilities the default entries can be left and all you need to do is click Next.
Congratulations, WAMP is now installed on your local computer.
Using one of the icons you created, or Start –> All Programs –> WampServer –> start WampServer, you can launch the management console. Once opened, it will appear an half circle like icon in the lower right hand corner of your screen .Click on that and you will see a popup list like below.
If WAMP is not started go ahead and click Start All Services. If you are not sure whether or not WAMP is running, look for the small green W icon in your toolbar. If it is red, WAMP services are stopped, green means everything is running while orange means some services are running.
Now we want to test to see if everything was installed correctly. In the WAMP management console, click on Localhost. If you see the following screen pop up in your browser then everything is working!
Now you have successfully installed Wamp server on your local computer.Now you can start to configure you web site in www folder in wamp foder .Suppose you install wamp server in C directory then your path is c://wamp/www/here_your_site_folder.
Happy Coding :)
While much of the web relies on a Linux, Apache, MySQL, PHP stack, or LAMP, to power applications and dynamic websites, not everyone codes in a Linux environment.
Those who prefer Windows can still replicate how their code will work by using WAMP to replicate a live web environment right on their own computer with the only difference being substituting the Linux operating system in the stack for Windows.
Obtain a copy of WAMP
Before you do anything you need to download WAMP from http://www.wampserver.com/en/download.php. You will have the option to choose wither a 32 or 64-bit environment depending upon your computer’s configuration. In addition to Apache, PHP and MySQL this download includes phpMyAdmin and SQLBuddy to better help you manage your databases through web based GUI rather than having to use a terminal interface.Install the software
Once you have downloaded and uncompressed your WAMP executable you will need to go ahead and launch it to start the installation process.When you click next you will be asked to accept the license agreement. Since it is a GPL license you are free to do just about anything with it so you can go ahead and accept.
The next step requires you to select the folder where you would like to install your WAMP server. The default will be c:\wamp however you can change this to install the server into any directory or partition you choose.
After you choose your directory you will have the option to setup icons. Once you decide on this click Next and then confirm the installation settings again by clicking Install.
Once the installation runs its course you will be asked to choose your default browser. Internet Explorer is the default choice but you can navigate your way to any other browser of your choosing.
NB – if your Windows firewall pops up at this point make sure to grant Apache access.
The next decision you will have to make is to set the PHP mail parameters. Many people leave this set to the defaults when setting up a testing server on their local computer. If you wish to configure it to connect to your SMTP server you may do so here but unless you plan on testing email capabilities the default entries can be left and all you need to do is click Next.
Congratulations, WAMP is now installed on your local computer.
Testing the installation
Now that everything has been installed let’s test everything out.Using one of the icons you created, or Start –> All Programs –> WampServer –> start WampServer, you can launch the management console. Once opened, it will appear an half circle like icon in the lower right hand corner of your screen .Click on that and you will see a popup list like below.
If WAMP is not started go ahead and click Start All Services. If you are not sure whether or not WAMP is running, look for the small green W icon in your toolbar. If it is red, WAMP services are stopped, green means everything is running while orange means some services are running.
Now we want to test to see if everything was installed correctly. In the WAMP management console, click on Localhost. If you see the following screen pop up in your browser then everything is working!
Now you have successfully installed Wamp server on your local computer.Now you can start to configure you web site in www folder in wamp foder .Suppose you install wamp server in C directory then your path is c://wamp/www/here_your_site_folder.
Happy Coding :)
Tags:
Php Basics