i'm trying to create virtual host ecommerce.com instead of php artisan serve, but too bad it direct to commerce.com site, knowing that I modify file D: \ wamp \ bin \ apache \ apache2.4.39 \ conf \ extra \ httpd-vhosts.conf
and C: \ Windows \ System32 \ Drivers \ etc \ host
.
host file
127.0.0.1 localhost
127.0.0.1 ecommerce.com
::1 localhost
httpd-vhosts.conf
# Virtual Hosts
#
<VirtualHost *:80>
ServerName localhost
ServerAlias localhost
DocumentRoot "${INSTALL_DIR}/www"
<Directory "${INSTALL_DIR}/www/">
Options +Indexes +Includes +FollowSymLinks +MultiViews
AllowOverride All
Require local
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerName ecommerce.com
DocumentRoot "${INSTALL_DIR}/www/ecomm/public"
<Directory "${INSTALL_DIR}/www/">
</Directory>
</VirtualHost>
When you use WAMP, you can create virtual hosts from the Wamp panel. In your browser go to localhost and in the wamp page find create virtual host
(or something like this).
I think it's better to undo the changes you've made manually first.