Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Abhisake Jain

    (@abhishj2)

    Hi,

    Thank you for reaching out!

    Depending on your site’s custom login page setup and SMTP mailer configuration, linking directly to WordPress’s native password reset handler ensures guaranteed email delivery across all mail configurations.

    You can easily enable this compatibility by adding the following snippet to your theme’s functions.php file (or via the Code Snippets plugin):

    add_action( 'init', function() {
    if ( 'POST' === $_SERVER['REQUEST_METHOD'] ) {
    $action = $_POST['rcp_action'] ?? $_POST['rc_action'] ?? '';
    if ( 'lostpassword' === $action ) {
    // Map legacy fields for compatibility
    $_POST['rcp_action'] = 'lostpassword';
    $_POST['rcp_lostpassword_nonce'] = $_POST['rcp_lostpassword_nonce'] ?? $_POST['rc_lostpassword_nonce'] ?? '';
    $_POST['rcp_user_login'] = $_POST['rcp_user_login'] ?? $_POST['rc_user_login'] ?? '';
    // Trigger standard WP password reset email delivery as fallback
    $user_login = sanitize_text_field( $_POST['rcp_user_login'] );
    if ( ! empty( $user_login ) && function_exists( 'retrieve_password' ) ) {
    retrieve_password( $user_login );
    }
    }
    }
    }, 5 );

    Best regards

    Plugin Support Abhisake Jain

    (@abhishj2)

    Hi,

    Thank you for reaching out!

    This notice can occur when dynamic page builders or custom query loops execute the_content filters before the global post object is initialized in PHP 8.2+.

    As a quick solution, you can add this small helper snippet to your theme’s functions.php file (or via the Code Snippets plugin). It ensures filters run only when full post context is available:

    add_filter( 'the_content', function( $content ) {
    global $post;
    if ( empty( $post ) || ! is_a( $post, 'WP_Post' ) ) {
    remove_filter( 'the_content', 'rcMetaDisplayNone' );
    remove_filter( 'the_content', 'rcMetaDisplaySubscriber' );
    remove_filter( 'the_content', 'rcMetaDisplayContributor' );
    remove_filter( 'the_content', 'rcMetaDisplayAuthor' );
    remove_filter( 'the_content', 'rcMetaDisplayEditor' );
    }
    return $content;
    }, 1 );

    Best Regards

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