Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

create custom domain in localhost xampp

//File path: ~/XAMPP/apache/conf/extra/httpd-vhosts.conf
<VirtualHost *:80>
  DocumentRoot "F:/XAMPP/htdocs/"
  ServerName localhost
</VirtualHost>
<VirtualHost *:80>
  DocumentRoot "F:/XAMPP/htdocs/todo-api"
  ServerName api.todo
</VirtualHost>
//Complete Path: C:WindowsSystem32driversetchosts
127.0.0.1 localhost
127.0.0.1 api.todo #Right Down ServerName
Source by medium.com #
 
PREVIOUS NEXT
Tagged: #create #custom #domain #localhost #xampp
ADD COMMENT
Topic
Name
3+8 =