Title: HTTPS and HTTP different content?
Last modified: August 30, 2016

---

# HTTPS and HTTP different content?

 *  Resolved [labsy](https://wordpress.org/support/users/labsy/)
 * (@labsy)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/)
 * Hi,
 * I am using latest WP with latest Wordfence plugin with my web site, which is 
   currently active on both, HTTPS and HTTP.
 * First off, I’d like to FORCE it using HTTPS only, but that’s minor problem.
 * Main problem is, that content of HTTP website is totally different of those via
   HTTPS. Actually, HTTP content is default/demo content of WP theme I use, while
   HTTPS content is what I actually wrote.
    I think this problem begun when I changed
   to HTTPS, but I am not sure, whether it is WP theme guilty, or Wordfence plugin.
 * Any idea?
 * [https://wordpress.org/plugins/wordfence/](https://wordpress.org/plugins/wordfence/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [WFBrian](https://wordpress.org/support/users/wfbrian/)
 * (@wfbrian)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/#post-6213559)
 * Hi,
 * Wordfence should be fine with HTTP or HTTPS.
 * -Brian
 *  [Radovan Smitala](https://wordpress.org/support/users/adorei/)
 * (@adorei)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/#post-6213640)
 * Hi,
 * im using version 6.0.7 and i think Wordfence has problem with HTTP vs HTTPS.
   
   Wordfence returns for both protocol same cached content. What is problem, because
   there are two different URL and need be two different cache content. Option “
   Allow SSL” in Performance tab is disabled. But i
 * My main url is HTTP but i have available HTTPS because Google.
    I change flow
   how WordPress handles SITE_URL constant. In wp-confing.php add this conditionals:
 *     ```
       if (isSecure()) {
         define('WP_HOME',   'https://' . $web_site_url);
         define('WP_SITEURL','https://' . $web_site_url);
         header( 'X-Secure-Connection: true' );
       } else {
         define('WP_HOME',   'http://' . $web_site_url);
         define('WP_SITEURL','http://' . $web_site_url);
       }
       ```
   
 * So when somebody (or Google crawler) use https, all my links are changed to secure.
   
   But if is only one version cached, it returns bad links (http in https content,
   so CSS and Scripts are not loaded).
 * I think Falcon engine should cache HTTP and HTTPS separately but it doesn’t
 * Regards!
    Radovan.
 *  [WFSupport](https://wordpress.org/support/users/wfsupport/)
 * (@wfsupport)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/#post-6213645)
 * This isn’t a standard configuration (I have never seen anyone do this before)
   so we wouldn’t really be able to support it. I am fairly certain there isn’t 
   anything in the code that would allows us to do this.
 * tim
 *  [Radovan Smitala](https://wordpress.org/support/users/adorei/)
 * (@adorei)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/#post-6213646)
 * I think same override do Woocommerce when is option “Force secure checkout” is
   enabled, so when website uses default only HTTP version its overload WP_HOME 
   and WP_SITEURL. Because if it dont do it, page will dont load CSS and JS files.
 * If it isnt standard configuration then i dont know why WordPress has helper function`
   is_ssl()`. I think it is completely normal, because you could conditional content.
 * Wordfence Basic Cache handles SSL and NON-SSL right. It saves and returns two
   diffrerent results. One for HTTP and for HTTPS.
 * Only Falcon engine uses just one cache file. (same for HTTP and HTTPS) so when
   is HTTP cached first, on HTTPS version it returns this HTTP cached file with 
   bad content (URLs are non secure for example) and it is error.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘HTTPS and HTTP different content?’ is closed to new replies.

 * ![](https://ps.w.org/wordfence/assets/icon.svg?rev=2070865)
 * [Wordfence Security - Firewall, Malware Scan, and Login Security](https://wordpress.org/plugins/wordfence/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordfence/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordfence/)
 * [Active Topics](https://wordpress.org/support/plugin/wordfence/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordfence/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordfence/reviews/)

## Tags

 * [HTTPS](https://wordpress.org/support/topic-tag/https/)

 * 4 replies
 * 4 participants
 * Last reply from: [Radovan Smitala](https://wordpress.org/support/users/adorei/)
 * Last activity: [10 years, 11 months ago](https://wordpress.org/support/topic/https-and-http-different-content/#post-6213646)
 * Status: resolved