Load password-verify and password-strength-meter in Default BP theme
-
Hello,
I see this code in buddypress\bp-templates\bp-legacy\buddypress-functions.php
// Maybe enqueue password verify JS (register page or user settings page) if ( bp_is_register_page() || ( function_exists( 'bp_is_user_settings_general' ) ) ) { // Locate the Register Page JS file $asset = $this->locate_asset_in_stack( "password-verify{$min}.js", 'js' ); $dependencies = array_merge( bp_core_get_js_dependencies(), array( 'password-strength-meter', ) ); // Enqueue script wp_enqueue_script( $asset['handle'] . '-password-verify', $asset['location'], $dependencies, $this->version); }
I copied it into functions.php of Default BP theme before:
add_action( 'wp_enqueue_scripts', 'bp_dtheme_enqueue_scripts' );
but I see following error: Fatal error: Using $this when not in object context in
How to load both files on Default BP theme?
- The topic ‘Load password-verify and password-strength-meter in Default BP theme’ is closed to new replies.