A
A
Alex Goncharov2017-09-27 12:39:03
Digital certificates
Alex Goncharov, 2017-09-27 12:39:03

How to force a redirect to https for a domain and all subdomains?

There is a site on Yii2 + AngularJS. How to force a redirect to https within the main domain and any of the subdomains?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrey, 2017-09-27
@VELIK505

add_header Strict-Transport-Security "max-age=31536000; includeSubDomains";

will force redirect to https when going to http domain and all its subdomains

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question