Redirect http to https (phpmyadmin)
Redirect http to https (phpmyadmin)
I'd like to redirect all requests from http://mydomain.com/phpmyadmin to https://mydomain.com/phpmyadmin. I know that before phpmyadmin 4.6 there's an option to force ssl via phpma config files. At the moment I have older version than 4.6 but for the future I need some other solution instead of the force ssl via config files.
When I tried to set "rewrite ^ https://mydomain.com$request_uri? permanent;" under /phpmyadmin location line I got "too many redirects" in Chrome.
I use nginx + php-fpm.
EDIT: I solved my problem by adding "return 301 https://$server_name$request_uri;" to my nginx config.
When I tried to set "rewrite ^ https://mydomain.com$request_uri? permanent;" under /phpmyadmin location line I got "too many redirects" in Chrome.
I use nginx + php-fpm.
EDIT: I solved my problem by adding "return 301 https://$server_name$request_uri;" to my nginx config.
Re: Redirect http to https (phpmyadmin)
ok, closed.solved by adding "return 301 https://$server_name$request_uri;" to my nginx config