How to run Laravel without Artisan?

前端 未结 11 2166
不思量自难忘°
不思量自难忘° 2020-12-05 03:24

I have PHP with Apache2 and I want to run Laravel Framework without Artisan but I can\'t! Does anyone know how to run Laravel without Artisan?

11条回答
  •  佛祖请我去吃肉
    2020-12-05 03:58

    Laravel with Vue.JS

    If you are using vue.js with Laravel and your app is not working without php artisan serve, you need to create a virtual host. This is a simple two-step process for windows.

    Step 1: Update you hosts file at C:\Windows\System32\drivers\etc with,

    127.0.0.1       dev.example #You can rename according to your app
    

    Step 2: Update you vhosts file with,

    I am using Apache which is installed in D:\ so my path for vhosts file is at D:\xampp\apache\conf\extra

    
        DocumentRoot "D:\xampp\htdocs\example\public" ##Your path 
        ServerName dev.example ##Your URL according to what you set in hosts file in step 1 
          ##Your path      
            Order allow,deny     
            Allow from all   
         
    
    

    That's it, now you can just visit your app at http://dev.example/

提交回复
热议问题