BSF_Extension_Installer::load_scripts( hook $hook )

Load scripts needed for extension installer.


Description


Parameters

$hook

(hook) (Required) current page hook.


Return

(void)


Source

File: admin/bsf-core/classes/class-bsf-extension-installer.php

	public function load_scripts( $hook ) {
		$bsf_ext_inst = apply_filters( 'bsf_extension_installer_screens', array( 'bsf-extensions' ), $hook );

		foreach ( $bsf_ext_inst as $key => $value ) {
			if ( false !== strpos( $hook, $value ) ) {
				wp_register_script( 'bsf-extension-installer', bsf_core_url( '/assets/js/extension-installer.js' ), array( 'jquery', 'wp-util', 'updates' ), BSF_UPDATER_VERSION, true );
				wp_enqueue_script( 'bsf-extension-installer' );
			}
		}
	}


User Contributed Notes

You must log in before being able to contribute a note or feedback.