Pages

Showing posts with label Laravel. Show all posts
Showing posts with label Laravel. Show all posts

Tuesday, September 1, 2020

Laravel Redirect HTTP to HTTPS via .htaccess

 Today, i share with you, redirect http to Https in laravel
You create file .htaccess in root laravel

 

RewriteEngine On
RewriteRule ^(.*)$ public/ [L]
 
Way code above it redirect to http, if you want http to https, 
you can using following code above 

 

<IfModule mod_rewrite.c>
    RewriteEngine On        
  RewriteCond %{HTTPS} !=on    
  RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
  RewriteRule ^(.*)$ public/ [L]
</IfModule>

Sunday, August 30, 2020

There is no existing directory at /storage/logs and its not buildable: Permission denied

 This issue is resolved by running 3 artisan commands in squence

php artisan route:clear

php artisan config:clear

php artisan cache:clear
It worked fine after running these commands.