Reputation: 1753
I am using laravel framework in ubunto system and I want to remove port number from my url
write now I can access my web-project with this url
http://localhost:8000
and I want this url
http://localhost/
How can I do this?
Upvotes: 3
Views: 4053
Reputation: 567
Do not use php artisan server in your commandline and use full URL path in browsers address bar as follows
http://localhost/projectname/public
Upvotes: 0
Reputation: 5509
80 is the default port number of http so you have to use this command to omit the port number:
sudo php artisan serve --host=localhost --port=80
Upvotes: 5
Reputation: 2793
If nothing else (e.g. Apache oder Nginx) uses port 80 you COULD start the development webserver like this
sudo php artisan serve --port 80
You can access the app via http://localhost/ afterwards
Note that this is ONLY for development and some kind of hack. Install a dedicated webserver (Apache, Nginx) for production :-)
Upvotes: 1