示例#1
0
 static function setPlugin(&$plg)
 {
     self::$plg = $plg;
 }
 function __construct()
 {
     parent::__construct("EzAdsLU", "Easy AdSense: Google Link Unit");
 }
        return $arg;
    }
    function filterFooter($arg)
    {
        if (is_admin()) {
            return $arg;
        }
        echo $this->leadout;
        return $arg;
    }
}
$ezAdSenseFront = new EzAdSenseFront();
if (!empty($ezAdSenseFront)) {
    add_filter('the_content', array($ezAdSenseFront, 'filterContent'));
    require_once 'easy-adsense-widget.php';
    EzWidget::setPlugin($ezAdSenseFront);
    if (EzGA::isPro()) {
        if (!empty(EzGA::$options['enableShortCode'])) {
            $shortCodes = array('ezadsense', 'adsense');
            foreach ($shortCodes as $sc) {
                add_shortcode($sc, array('EzGAPro', 'processShortcode'));
            }
        }
    }
    if (EzGA::$options['max_link'] === -1) {
        add_action('wp_footer', array($ezAdSenseFront, 'showUnreal', 1));
    }
    if (!empty(EzGA::$options['header_leadin'])) {
        add_action(EzGA::$options['header_leadin'], array($ezAdSenseFront, 'filterHeader'));
    }
    if (!empty(EzGA::$options['footer_leadout'])) {