function __construct() { parent::__construct(); // This is the funky way I do it so it works with my symlinks $plugin_url = plugins_url(basename(dirname(__FILE__))) . "/"; $plugin_version = $this->version; load_plugin_textdomain('simple-fields-field-googlemaps', false, basename(dirname(__FILE__)) . '/languages'); // Add admin scripts that the the plugin uses add_action("admin_enqueue_scripts", function () use($plugin_url, $plugin_version) { wp_enqueue_script("simple-fields-googlemaps", $plugin_url . "scripts.js", array(), $plugin_version); wp_enqueue_style("simple-fields-googlemaps", $plugin_url . "style.css", array(), $plugin_version); }); }
function __construct() { parent::__construct(); }
function __construct() { parent::__construct(); add_action('simple_fields_admin_head', array($this, 'action_admin_head')); add_action('simple_fields_enqueue_scripts', array($this, 'enqueue_scripts')); }
function __construct() { parent::__construct(); // add some styling in the admin head add_action('admin_head', array($this, 'action_admin_head')); }