<?php //Requires require_once '/data/project/xtools/public_html/WebTool.php'; require_once '/data/project/xtools/public_html/articleinfo/base.php'; ini_set("display_errors", 1); ini_set("memory_limit", '512M'); //Load WebTool class $wt = new WebTool('ArticleInfo', 'articleinfo'); /*Update me*/ $wtSource = "//code.google.com/p/soxred93tools/source/browse/trunk/web/articleinfo"; $wtTranslate = true; WebTool::setMemLimit(); //Show form if &article parameter is not set (or empty) if (!$wgRequest->getSafeVal('getBool', 'article')) { $content->assign('form', $curlang); WebTool::assignContent(); } //Now load configs for the graph templates $linegraph = new Smarty(); $sizegraph = new Smarty(); if (is_file('configs/' . $curlang . '.conf')) { $linegraph->config_load($curlang . '.conf', 'articleinfo'); $sizegraph->config_load($curlang . '.conf', 'articleinfo'); } else { $linegraph->config_load('en.conf', 'articleinfo'); $sizegraph->config_load('en.conf', 'articleinfo'); } //Set the article variables $article = trim(str_replace(array(''', '%20'), array('\'', ' '), $wgRequest->getSafeVal('article'))); $article = urldecode($article);
<?php //Requires require_once '/data/project/xtools/public_html/WebTool.php'; require_once '/data/project/xtools/public_html/blame/base.php'; // set some global vars $pgVerbose = false; //Load WebTool class $wt = new WebTool('Blame', 'blame', array('getwikiinfo', 'peachy', 'database')); $wtTranslate = true; WebTool::setMemLimit(256); $siteNoticeClass = new siteNotice(); $sitenotice = $siteNoticeClass->checkSiteNoticeRaw(); if ($sitenotice) { $phptemp->assign("alert", $sitenotice); } // get params from query string $lang = $wgRequest->getSafeVal('lang'); $wiki = $wgRequest->getSafeVal('wiki'); $article = $wgRequest->getSafeVal('article'); $nofollowredir = $wgRequest->getBool('nofollowredir'); $text = isset($_GET["text"]) ? urldecode($_GET["text"]) : ""; $wikibase = $lang . '.' . $wiki . '.org'; //Show form if &article parameter is not set (or empty) if ($lang == "" || $wiki == "" || $article == "" || $text == "") { $content->assign('form', 'en'); WebTool::assignContent(); WebTool::toDie(""); } // execute the main logic $revs = BlameBase::getBlameResult($wikibase, $article, $nofollowredir, $text);