How to deploy laravel 4.2 on shared hosting?

后端 未结 5 1425
遇见更好的自我
遇见更好的自我 2020-12-09 06:00

I developed an application with laravel 4.2.8 and now I am having trouble deploying it. I followed this answer https://stackoverflow.com/a/16683938/3153380 but its not worki

5条回答
  •  执笔经年
    2020-12-09 06:46

    Try to play with .htaccess

    In your public_html, add a .htaccess to forward the request

    
        RewriteEngine on
        RewriteCond %{REQUEST_URI} !^yoursite.com/public
        RewriteRule ^(.*)$ yoursite.com/public/$1 [L]
    
    

    i.e.

    public_html
    ├── yoursite.com    <-------- laravel project
    ├── .htaccess       <-------- this file
    

提交回复
热议问题