Configuring a virtual host under Windows

Source: Internet
Author: User

The first step is to open the httpd-vhosts.conf under the Apache/conf/extra folderin the second step, add the following code<virtualhost *:80> ServerAdmin myself.plug.com documentroot "D:\workspace\cbec-v2\amin\web" # # fill in the local YII2 project directoryServerName cbec.product.com # # set the virtual host name<directory "D:/workspace/cbec-v2/amin/web" > # # fill in the local YII2 project directory (note forward slash)Options Indexes followsymlinks allowoverride all Order allow,deny to all </directory></virtua Lhost>step three, modify the Hosts file in the C:\Windows\System32\drivers\etc directory Note: You must use Administrator privileges to modifyStep: 1, enter Notepad in the Windows Search file box, the corresponding Notepad.exe2 will appear. Right-run 3 as Administrator, select File in Notepad/Open 4, select all files in the bottom right corner, select hosts, open 5, add the following : 127.0.0.1 Virtual Host Name

Configuring a virtual host under Windows

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.