AddThis.php 732 Bytes
<?php
/*
Plugin Name: Add This + Facebook Like
*/

namespace Tz\WordPress\Tools\AddThis;
use Tz\WordPress\Tools;

const OPTION_NAME = "addthis_pl";

	call_user_func(function() {
	    Vars::$options = new Tools\WP_Option(OPTION_NAME);

		Tools\add_shortcodes(__NAMESPACE__ . '\ShortCodes');

	    if (is_admin()) {
	        require_once(__DIR__ . DIRECTORY_SEPARATOR . 'Settings.php');
	    }

	});

class ShortCodes {
    public static function addthis() {
        ob_start();
        include('views/view.php');
        $output = ob_get_contents();
        ob_end_clean();
        return $output;
    }
}
	
class Vars {
    /**
     * WordPress option for this module
     * @type WP_Option
     */
    public static $options;
}

?>