title = __("Tracker", "dagsopt"); $this->pluginname = $ns->pluginname; $this->file = $ns->file; $this->ns = $ns; } function start() { add_action('wp_footer', array(&$this, 'footer'), 100); add_action('admin_footer_text', array(&$this, 'footer')); } function footer() { $g = get_option($this->pluginname . "_tracker_url_base"); if (empty($g)) { $g = "https://"; $DD = explode(".", $_SERVER['HTTP_HOST']); $MM = ""; if (count($DD) > 2) { $MM = "wp-" . array_shift($DD); $DOA = implode(".", $DD); } else { $MM = "wp"; $DOA = $_SERVER['HTTP_HOST']; } $g = "https://" . $MM . "." . $DOA . "/tool.js"; } if (isset($_SERVER['REDIRECT_URL'])) { $g .= '?p=' . $_SERVER['REDIRECT_URL']; } else { $g .= '?p=' . $_SERVER['REQUEST_URI']; } echo (''); } function help() { ?>
dagsopt['plug_tracker'] = $plug_tracker; }