Log In Link Under the MemberPress Unauthorized Message
Adds a "Already a member? Log in" link below the MemberPress access-denied message, returning members to the same page after login.
Opens WPIDE on
Code
<?php if ( ! is_user_logged_in() ) : ?>
<p class="wpide-mepr-login-link">
Already a member?
<a href="<?php echo esc_url( wp_login_url( get_permalink() ? get_permalink() : home_url( '/' ) ) ); ?>">Log in to continue reading</a>.
</p>
<?php endif; ?>
How to add this snippet
- Install WPIDE on your WordPress site (it is free) and open Code Snippets.
- Use snippet above adds it from the library in one click. Or copy the code into a new snippet with the same code type.
- It is added inactive: review the code and settings, then switch it on.