PUM_Modules_Admin_Bar::enqueue_files()

Enqueues and prepares our styles and scripts for the admin bar


Description Description


Source Source

File: includes/modules/admin-bar.php

	public static function enqueue_files() {
		if ( ! self::should_render() ) {
			return;
		}
		$suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
		wp_enqueue_script( 'pum-admin-bar', Popup_Maker::$URL . 'assets/js/admin-bar' . $suffix . '.js', array( 'jquery' ), Popup_Maker::$VER, true );
		wp_enqueue_style( 'pum-admin-bar-style', Popup_Maker::$URL . 'assets/css/pum-admin-bar' . $suffix . '.css', array(), Popup_Maker::$VER );

		$admin_bar_text = array(
			'instructions' => __( 'After clicking ok, click the element you want a selector for.', 'popup-maker' ),
			'results' => _x( 'Selector', 'JS alert for CSS get selector tool', 'popup-maker' ),
		);
		wp_localize_script( 'pum-admin-bar', 'pumAdminBarText', $admin_bar_text );
	}

Top ↑

Changelog Changelog

Changelog
Version Description
1.11.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

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