plugin incompatibility with Leaflet Maps Marker / Maps Marker Pro
-
Hi,
I am the developer of Leaflet Maps Marker respectively Maps Marker Pro and a user reported an incompatibility with your seo plugin. If you plugin is active, your scripts and styles not only get enqueued on specific/needed but all WordPress admin pages, this breaks the layout of my settings page:<img src=”http://i62.tinypic.com/ivfw4l.png” border=”0″ alt=”Image and video hosting by TinyPic”>
Within my plugins I use the following approach to only enqueue my scripts/styles on backend where needed:
[...] $page5 = add_submenu_page('leafletmapsmarker_markers',__('add/edit layer', 'lmm'), __('Add new layer', 'lmm'), $lmm_options[ 'capabilities_edit' ], 'leafletmapsmarker_layer', array(&$this, 'lmm_layer') ); [...] add_action('admin_print_scripts-'.$page5, array(&$this, 'lmm_admin_enqueue_scripts'),8); [...] function lmm_admin_enqueue_scripts() { global $wp_version; $lmm_options = get_option( 'leafletmapsmarker_options' ); wp_enqueue_script( 'leafletmapsmarker-core', LEAFLET_PLUGIN_URL_ENC . 'leaflet-dist/leaflet-core.js', array(), $plugin_version, false); wp_enqueue_script( 'leafletmapsmarker-addons', LEAFLET_PLUGIN_URL_ENC . 'leaflet-dist/leaflet-addons.js', array('leafletmapsmarker-core' ), $plugin_version, false); [...] }it would be great if you could also add this to your plugin, as this not only fixes the incompatibility with my plugins, but also speeds up the WordPress admin area in general if your plugin is active, as less http requests would be needed.
thx,Robert
The topic ‘plugin incompatibility with Leaflet Maps Marker / Maps Marker Pro’ is closed to new replies.