Redirect non-www to www https exclude subdomains

ساخت وبلاگ

Yesterday, 06:12 PM #1

I'm looking all over the internet, but nothing works like I want to, or with speed testers I get messages that I have to reduce redirects.
Most of what I found did not work or only worked half.

This is what I want to do:
1.) Redirect all http to https including subdomains.

2.) Redirect all http://domain.com to https://www.domain.com (so non-www to www)

3.) I do NOT want -any- subdomdain https://*(except www).domain.com to be redirected to https://www.*.domain.com
So I don't want http or https:/sub.domain.com redirected to https://www.sub.domain.com but only to https://sub.domain.com
Same for other subdomains.

If 3.) is not possible, I would like at least 1 subdomain from http to https without www but just as https://sub.domain.com.

I would like to do this in a .htaccess file in the best way possible (less redirects possible).
Please do not point to apache documentation, I've read that, I'm not English and I only get more confused.

Last edited by Richard G; Yesterday at 06:20 PM.

Greetings, Richard.


DirectAdmin Forums...
ما را در سایت DirectAdmin Forums دنبال می کنید

برچسب : نویسنده : ایمان اصلاحی directadmin بازدید : 373 تاريخ : دوشنبه 27 آذر 1396 ساعت: 18:28