WordPress.org

Ready to get started?Download WordPress

Forums

s2Member Framework (Member Roles, Capabilities, Membership, PayPal Members)
Load password-strength-meter only on needed pages. (1 post)

  1. Chumlee
    Member
    Posted 1 year ago #

    Cause it loads on all of them. It sure does not help in decreasing load time. So I've thought to help some people who may be into the user experience thing.
    In plugings/s2member/includes/classes/css-js-themes.inc.php ( Line:83 & 87 )
    before

    wp_enqueue_script ("ws-plugin--membership", $s2o . "?membership_js_w_globals=" . urlencode ($md5) . "&qcABC=1", array ("jquery", "password-strength-meter"), c_membership_utilities::ver_checksum ());

    and

    wp_enqueue_script ("ws-plugin--membership", $s2o . "?membership_js_w_globals=1&qcABC=1", array ("jquery", "password-strength-meter"), c_membership_utilities::ver_checksum ());

    add :

    if( $hook != 'users.php' && $hook != 'wp-login.php' ) return;

    or your own custom .php file. I just did an example.
    Done. Now one thing less to worry about.

    Otherwise. Great work the plugin!

    http://wordpress.org/extend/plugins/s2member/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic