Title: Menu redirecting to &#039;http&#039; home page as &#039;https&#039;
Last modified: August 21, 2016

---

# Menu redirecting to 'http' home page as 'https'

 *  Resolved [Akshay](https://wordpress.org/support/users/akshayadhav/)
 * (@akshayadhav)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/menu-redirecting-to-http-home-page-as-https/)
 * Hi,
 * It’s really a great plugin. Thanks for it.
    I have an issue with the wordpress
   menu. I’ve made a single page ssl secured. But when I redirect to Home page through
   Menu from the secured page, it treats the home page as secured which I don’t 
   want. How to keep the home page with ‘http’ protocol?
 * Thanks & regards,
    Akshay
 * [https://wordpress.org/plugins/ssl-insecure-content-fixer/](https://wordpress.org/plugins/ssl-insecure-content-fixer/)

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

 *  Thread Starter [Akshay](https://wordpress.org/support/users/akshayadhav/)
 * (@akshayadhav)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/menu-redirecting-to-http-home-page-as-https/#post-4643757)
 * Hi,
    Got the answer after searching a lot. [From this link](http://www.wpwhitesecurity.com/wordpress-security/definitive-guide-wordpress-ssl-setup/)
   Here’s the code:
 *     ```
       function force_ssl()
       {
           // Specify ID of page to be viewed on SSL connection
           if (is_page(2324) && !is_ssl () )
           {
             header('HTTP/1.1 301 Moved Permanently');
             header("Location: https://" . $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"]);
             exit();
           }
           // All other pages must not be https
           else if (!is_page(2324) && is_ssl() )
           {
               header('Location: http://' . $_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']);
               exit();
           }
       }
       add_action('template_redirect', 'force_ssl');
       ```
   
 *  Plugin Author [webaware](https://wordpress.org/support/users/webaware/)
 * (@webaware)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/menu-redirecting-to-http-home-page-as-https/#post-4643878)
 * Good work 🙂

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

The topic ‘Menu redirecting to 'http' home page as 'https'’ is closed to new replies.

 * ![](https://ps.w.org/ssl-insecure-content-fixer/assets/icon-256x256.png?rev=2590634)
 * [SSL Insecure Content Fixer](https://wordpress.org/plugins/ssl-insecure-content-fixer/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ssl-insecure-content-fixer/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ssl-insecure-content-fixer/)
 * [Active Topics](https://wordpress.org/support/plugin/ssl-insecure-content-fixer/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ssl-insecure-content-fixer/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ssl-insecure-content-fixer/reviews/)

## Tags

 * [https to http](https://wordpress.org/support/topic-tag/https-to-http/)
 * [SSL](https://wordpress.org/support/topic-tag/ssl/)

 * 2 replies
 * 2 participants
 * Last reply from: [webaware](https://wordpress.org/support/users/webaware/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/menu-redirecting-to-http-home-page-as-https/#post-4643878)
 * Status: resolved