Title: HTTPS different Site Address (URL)
Last modified: August 30, 2016

---

# HTTPS different Site Address (URL)

 *  Resolved [OviLiz](https://wordpress.org/support/users/ovib/)
 * (@ovib)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/)
 * I have a HTTPS blog with the WordPress Address (URL) like [https://blog.mydomain.com](https://blog.mydomain.com)
   while I have changed the Site Address (URL) is [https://mydomain.com/blog](https://mydomain.com/blog)
 * Is everything ok, but I want to force accessing only through HTTPS, so avoid 
   HTTP.
 * I have found this on your forum:
 *     ```
       # WP REWRITE LOOP START
       RewriteEngine On
       RewriteBase /
       RewriteCond %{HTTPS} !=on
       RewriteCond %{SERVER_PORT} ^80
       RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R,L]
       RewriteRule ^index\.php$ - [L]
       ```
   
 * But using it the URL address become [https://blog.mydomain.com/blog](https://blog.mydomain.com/blog)
 * Is there any way to avoid that?
 * PS. I’m not receiving your forum registration email (already checked Gmail spam,
   tried twice etc.).
 * [https://wordpress.org/plugins/bulletproof-security/](https://wordpress.org/plugins/bulletproof-security/)

Viewing 15 replies - 1 through 15 (of 21 total)

1 [2](https://wordpress.org/support/topic/https-different-site-address-url-1/page/2/?output_format=md&replies=19)
[→](https://wordpress.org/support/topic/https-different-site-address-url-1/page/2/?output_format=md&replies=19)

 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622140)
 * > I’m not receiving your forum registration email (already checked Gmail spam,
   > tried twice etc.
 * Yep, we are aware of the email problem with our Host Mail server. It is an intermittent
   problem that has been going on for about 3 weeks now. About 40% of automated 
   emails (wp_mail(), mail()) are never sent or are being junked or are going to
   the Twilight Zone. So far we do not have an answer from our host. Something like
   this problem could take a long time to get fixed, but after enough customers 
   complain it will eventually get fixed by our Host. 😉
 * What I need to know first is what is your actual physical folder structure for
   this site?
    Example: /blog/ – subdomain site and folder at the root of hosting
   account /mydomain.com/blog/ – subfolder site of root site mydomain.com
 * What I need to know next is is this a real subdomain site and have you setup 
   a subdomain in your Hosting account using an A or CNAME record?
 * Next, why do you want to change the URL? Why is the URL not the same for both
   WordPress Address (URL) and Site Address (URL)?
 * Next, what type of site is this? Single standard WordPress installation? Network/
   Multisite? Giving WordPress Its Own Directory (GWIOD)?
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622142)
 * Yeah now the intermittent Host server problems that have been occurring for the
   last 3 weeks have started occurring again today. All of our sites are down again.
   fun stuff.
 *  Thread Starter [OviLiz](https://wordpress.org/support/users/ovib/)
 * (@ovib)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622155)
 * Strange you’ve got this issues with GoDaddy…
    How many visitors do you have? 
   I can host you for free in a quiet MediaTemple (gs) shared account. 🙂
 * Turning back to my question, I’m not using Multisite. WP is installed in the 
   root folder (so no subfolders) and yes, there is an A record for the subdomain.
   
   The reason is a bit complicated and I believe doesn’t help the case. 🙂 However
   I’m using a CodeIgniter app in a different server with the main domain and I 
   don’t want WP code on that server and I want the blog link to not disorient the
   visitors as the template is pretty similar. On that server I’m using nginx with
   proxy_pass the /blog/ link to the subdomain.
 * Is working fine without any HTTPS rule, but in this case anyone can access directly
   the subdomain without HTTPS too. So I wish to avoid that. 🙂
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622157)
 * We have been with our Host for over 5 years and this type of major problem has
   never occurred before. Yeah minor hiccups and bumps in the road just like any
   Host has, but nothing this major. It was/is a global outage thing and not just
   our particular servers/sites. I’m hoping that it is over, but have the feeling
   that interim patches are being used for something much bigger like a major Infrastructure
   problem. I was a System Administrator for a 10,000+ Node computer Network and
   all the symptoms and signs (Host Tracker, etc) indicate a major Infrastructure
   problem is occurring.
 * Ok then what is probably happening is that you are redirecting https to http 
   and that will either cause infinite redirect looping problems or exactly what
   you are seeing. check your server logs for infinite redirect loop error or other
   errors.
 * > IMPORTANT NOTES:
   >  All of your website URL’s/URI’s/links MUST be https and NOT
   > http or else the http to https redirect will NOT work correctly and you will
   > see infinite redirect loop errors. If you are seeing errors or problems then
   > right mouse click on your website page(s), click the View Source menu command(
   > or similar name in other Browsers) to view the Source Code of your website 
   > page(s). Look for any URL/URI’s/link Schemes (http|https) that are still http
   > and NOT https. You will need to correct/fix any URL’s/URI’s/links that are 
   > still http and NOT https. Example: If you have an https page and the image 
   > file links are http then you will see infinite redirect errors (and probably
   > other errors) and pages will NOT redirect correctly. When you change your WordPress
   > General Settings to https, all images that have been added to Posts or Pages
   > using the Add Media button will automatically have https links. If you have
   > hard coded an http link in a Post or Page then those are the links you will
   > need to manually change to https.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622158)
 * Also since this is a GWIOD WordPress setup then make sure you are doing all the
   GWIOD things correctly: [https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory](https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory)
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622159)
 * Logically I think all that is happening is your site root htaccess file ALSO 
   needs to have the SSL/HTTPS code added to it.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622160)
 * One other thing. I see from your thread post history that you are using the Sucuri
   plugin. If you are using the wp-content one-click hardening option then use FTP
   and manually delete this htaccess file here: /wp-content/.htaccess.
    Or you can
   add additional whitelisting code in that Sucuri wp-content htaccess file: [https://wordpress.org/support/topic/sucuri-1-click-hardening-wp-content-htaccess-file-problem-detected?replies=9#post-6087304](https://wordpress.org/support/topic/sucuri-1-click-hardening-wp-content-htaccess-file-problem-detected?replies=9#post-6087304)
 *  Thread Starter [OviLiz](https://wordpress.org/support/users/ovib/)
 * (@ovib)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622161)
 * Ok, let me try being more clear.
 * – WP is installed in root and is using a subdomain (blog.mydomain.com).
    – I 
   have changed the Site Address URL to [https://mydomain.com/blog](https://mydomain.com/blog)
   while the path is still [https://blog.mydomain.com](https://blog.mydomain.com)–
   I have already changed all the DB HTTP to HTTPS and I don’t have any issue with
   that.
 * Everything is working fine but my blog is being reachable via both HTTP and HTTPS(
   [http://mydomain.com/blog](http://mydomain.com/blog) and [https://mydomain.com/blog](https://mydomain.com/blog)).
   
   In order to prevent this, there is the classic HTTPS code. But in this case the
   URL is being changed into [https://blog.mydomain.com/blog](https://blog.mydomain.com/blog)
   and is still working without any loop.
 * I believe I should change in the default HTTPS code, %{HTTP_HOST} in something
   like %{WP_SITEURL} but recognisable by htaccess.
 * PS. I’m not using Sucuri anymore.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622162)
 * So is the physical folder named: /blog/ for the subdomain site?
 * Example:
    We have several subdomain sites. DNS A Records point to these subdomain
   sites. /api/ /forum/ /affiliates/
 * The URI|URL’s are:
    api.ait-pro.com forum.ait-pro.com affiliates.ait-pro.com
 * WordPress URL settings in our case:
    WordPress Address and Site Address `http://
   subdomain-name.ait-pro.com`
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622163)
 * Additional info added to above reply #post-7517269
 *  Thread Starter [OviLiz](https://wordpress.org/support/users/ovib/)
 * (@ovib)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622192)
 * It is in the root, public_html/*
    public_html/wp-content public_html/wp-config.
   php public_html/etc…
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622193)
 * What is in the root public_html folder?
    Example: public_html/blog/ – this is
   the subdomain site folder|directory in the hosting account root folder public_html/
   mydomain.com/ – this site is in this hosting account root folder
 * Without knowing what your folder|directory structure is I cannot give you any
   kind of answer. I need to know if your folder|directory structure is correct 
   or to be able to tell you what htaccess code will work based on your structure.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622194)
 * If you are worried that you are exposing something publicly that should not be
   exposed then do not worry about that because your folder structure is already
   displayed publicly in your website URL|URI.
 * Example:
    /forum/ is displayed publicly in this URI|URL: forum.ait-pro.com
 *  Thread Starter [OviLiz](https://wordpress.org/support/users/ovib/)
 * (@ovib)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622218)
 * Are you actually the same person from the beginning of this thread to the end?
   😀
 * I believe I was clear from the beginning what I was aiming and until the end 
   I had to repeat myself multiple times.
 * If you don’t have any idea how to force using HTTPS on sites with **Site Address(
   URL)** that are different than the **WordPress Address (URL)**, just let me know.
   🙂
    Is not a big issue by the end of the day. I wouldn’t force using HTTPS so
   people would be able to access both [http://www.mydomain.com/blog](http://www.mydomain.com/blog)
   and [https://www.mydomain.com/blog](https://www.mydomain.com/blog) if there is
   no way forcing using just the last one.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/#post-6622223)
 * Yes, same person. What you have posted so far does not tell me exactly what your
   folder structure is. What I need to know exactly is what is the folder name that
   the blog site is in?
 * > It is in the root, public_html/*
 * If this is your answer above then that is the problem. A subdomain site needs
   to be in it is own separate folder.
    Example: /public_html/subdomain/

Viewing 15 replies - 1 through 15 (of 21 total)

1 [2](https://wordpress.org/support/topic/https-different-site-address-url-1/page/2/?output_format=md&replies=19)
[→](https://wordpress.org/support/topic/https-different-site-address-url-1/page/2/?output_format=md&replies=19)

The topic ‘HTTPS different Site Address (URL)’ is closed to new replies.

 * ![](https://ps.w.org/bulletproof-security/assets/icon-128x128.png?rev=1731938)
 * [BulletProof Security](https://wordpress.org/plugins/bulletproof-security/)
 * [Support Threads](https://wordpress.org/support/plugin/bulletproof-security/)
 * [Active Topics](https://wordpress.org/support/plugin/bulletproof-security/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bulletproof-security/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bulletproof-security/reviews/)

 * 21 replies
 * 2 participants
 * Last reply from: [AITpro](https://wordpress.org/support/users/aitpro/)
 * Last activity: [10 years, 8 months ago](https://wordpress.org/support/topic/https-different-site-address-url-1/page/2/#post-6622229)
 * Status: resolved