First thing you need to do is install a latest wamp server on your system.
Once setup is done. Start the WAMP server.
Default link to access WAMP server is http://localhost/.
Now if you create a new website folder under htdocs named website so the default link to run the new project is http://localhost/website
If you want to rename the link from http://localhost/website to suppose http://website.com that is creating a virtual host you need to follow below steps:
- Goto your My Computer > C > windows > system32 > drivers > etc
Edit hosts file using admin rights
- Once hosts file is opened. Right at bottom of file add following code
website.com is host name which i want to run as and save the file
- Then, Go to wamp installation folder: apache >conf > extra
and edit httpd-vhosts.conf file
- Once file is opened as following code at bottom of file. This code gives permission to virtual host to folder
Order Deny, Allow
Allow from all
- Now restart your server and run host as http://website.com and it will point to www/website folder.