Designersblog.net Description: A great plugin from the developers of Designersblog.net that will send a popup to people who have the Adblock browser extension installed. Copyright 2012 Designersblog.net (email : info@buitengewoonuniek.nl ) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ if (!class_exists("DesignersblogAdblockblocker")) { class DesignersblogAdblockblocker { function DesignersblogAdblockblocker() { // constructor } } } // End Class DesignersblogAdblockblocker if (class_exists("DesignersblogAdblockblocker")) { $dl_pluginSeries = new DesignersblogAdblockblocker(); } // Actions and Filters if (isset($dl_pluginSeries)) { //Start function AdblockBlockerHead() { include('scripts/loadhead.php'); wp_enqueue_script("jquery"); } function AdblockBlockerFooter() { include('scripts/loadfooter.php'); } add_action('wp_head','AdblockBlockerHead'); add_action('wp_footer','AdblockBlockerFooter'); } // Add settings link on plugin page function your_plugin_settings_link($links) { $settings_link = 'Settings'; array_unshift($links, $settings_link); return $links; } $plugin = plugin_basename(__FILE__); add_filter("plugin_action_links_$plugin", 'your_plugin_settings_link' ); register_activation_hook(__FILE__,'db_adblock_blocker_install'); register_deactivation_hook( __FILE__, 'db_adblock_blocker_remove' ); function db_adblock_blocker_install() { add_option("db_adblock_blocker_data_text", 'It seems like you have the browser extension Adblock installed. Please consider disabling this extension before visiting our website.', 'This is my first plugin panel data.', 'yes'); add_option("db_adblock_blocker_data_title", 'Adblock detected', 'This is my first plugin panel data.', 'yes'); add_option("db_adblock_ugroup", 'a:1:{s:9:"reg_users";s:4:"true";}', '', 'yes'); add_option("db_adblock_allpages", 'a:1:{s:4:"page";s:5:"all";}', '', 'yes'); } function db_adblock_blocker_remove() { delete_option('db_adblock_blocker_data_text'); delete_option('db_adblock_blocker_data_title'); delete_option('db_adblock_ugroup'); delete_option('db_adblock_allpages'); } add_action('admin_menu', 'db_adblock_blocker_admin_menu'); function db_adblock_blocker_admin_menu() { add_options_page('Plugin Admin Options', 'Adblock blocker', 'manage_options', 'Adblock-blocker', 'plugin_admin_options_page'); } ?>

Adblock blocker settings

Adblock blocker - main text settings

Title:

Main text:


Adblock blocker - Show settings

Show settings:

Show Adblock-popup to registered users?

/> Yes /> No

Show Adblock-popup on the following pages:

/> All /> Only on index/home /> Only on posts/pages