/** * Refine admin notices, have to do this before the UI is actually loaded. */ function refine_notices() { // make sure we use the correct action $action = is_multisite() ? 'network_admin_notices' : 'admin_notices'; /** We know we're on a Connect page, adjust things... */ if (isset($_GET['page']) && false !== strpos($_GET['page'], $this->slug)) { remove_all_actions('admin_notices'); } // only network admins and single install admins can install/activate etc.. if (!pl_can_use_tools('update_core')) { return false; } /** * Conversion Flow */ if (!$this->oauth->is_connected()) { if ($this->page() != 'account') { add_action($action, array($this, 'connect_account_notice')); } } elseif (!$this->has_installed_something()) { add_action($action, array($this, 'notice_install_something')); } elseif (!$this->is_pro()) { add_action($action, array($this, 'notice_upgrade_site')); } if (!$this->is_framework_installed() && !isset($_GET['theme'])) { add_action($action, array($this, 'notice_install_framework')); } if (!pl_is_professional()) { add_action($action, array($this, 'notice_pro_plugins')); } }
function pl_cred() { $cred = sprintf('<div class="pl-cred"><a href="%s" title="%s"><i class="pl-icon pl-icon-pagelines"></i></a></div>', PL()->urls->pagelines, __('Built With PageLines for WordPress', 'pl-platform')); if (pl_user_setting('hide_pl_cred') && true == pl_is_professional()) { $cred = ''; } return apply_filters('pl_cred', $cred); }