How to set a domain name with php artisan serve



PHP Snippet 1:


# localhost name resolution is handled within DNS itself.
#   127.0.0.1       localhost
#   ::1             localhost
127.0.0.1           blog.local

PHP Snippet 2:

php artisan serve --host=blog.local --port=8001

PHP Snippet 3:

php artisan serve --host=example.com

PHP Snippet 4:

php artisan serve --host=<host IP address> --port=<port to use>

PHP Snippet 5:

php artisan serve --host=127.0.0.1 --port=8080

PHP Snippet 6:

php artisan serve --host=<your_domain_name_in_the_host_file> 

PHP Snippet 7:

php artisan serve --host=lala.com
Laravel development server started: http://lala.com:8000

PHP Snippet 8:

php artisan serve --host=lala.com --port=8088