Skip to content

Instantly share code, notes, and snippets.

@strangerstudios
Created September 29, 2013 16:54
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save strangerstudios/6754247 to your computer and use it in GitHub Desktop.
Disable PMPro's HTTP/HTTPS redirect code.
<?php
/*
Plugin Name: PMPro Disable HTTP/HTTPS Redirect
Plugin URI: http://www.paidmembershipspro.com/wp/pmpro-disable-https-redirect/
Description: Disables the function in PMPro that redirects HTTP to HTTPS and vice versa.
Version: 1.0
Author: Stranger Studios
Author URI: http://www.strangerstudios.com
*/
function pmpro_dhr_init()
{
remove_action('wp', 'pmpro_besecure', 2);
remove_action('login_init', 'pmpro_besecure', 2);
}
add_action("init", "pmpro_dhr_init", 20);
@laurenhagan0306
Copy link

This recipe is included in the blog post on "Troubleshooting HTTPS/SSL Issues" at Paid Memberships Pro here: https://www.paidmembershipspro.com/debugging-httpsssl-issues/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment