Пример #1
0
 function execute($par)
 {
     global $wgRequest, $wgUser, $wgOut;
     wfLoadExtensionMessages('RequestTopic');
     $pass_captcha = true;
     if ($wgRequest->wasPosted()) {
         $fc = new FancyCaptcha();
         $pass_captcha = $fc->passCaptcha();
     }
     $wgOut->setPageTitle(wfMsg('suggest_header'));
     if ($wgRequest->wasPosted() && $pass_captcha) {
         $dbr = wfGetDB(DB_SLAVE);
         require_once 'EditPageWrapper.php';
         $title = EditPageWrapper::formatTitle($wgRequest->getVal('suggest_topic'));
         $s = Title::newFromText($title);
         if (!$s) {
             $wgOut->addHTML("There was an error creating this title.");
             return;
         }
         // does the request exist as an article?
         if ($s->getArticleiD()) {
             $wgOut->addHTML(wfMsg('suggested_article_exists_title'));
             $wgOut->addHTML(wfMsg('suggested_article_exists_info', $s->getText(), $s->getFullURL()));
             return;
         }
         // does the request exist in the list of suggested titles?
         $email = $wgRequest->getVal('suggest_email');
         if (!$wgRequest->getCheck('suggest_email_me_check')) {
             $email = '';
         }
         $count = $dbr->selectField('suggested_titles', array('count(*)'), array('st_title' => $s->getDBKey()));
         $dbw = wfGetDB(DB_MASTER);
         if ($count == 0) {
             $dbw->insert('suggested_titles', array('st_title' => $s->getDBKey(), 'st_user' => $wgUser->getID(), 'st_user_text' => $wgUser->getName(), 'st_isrequest' => 1, 'st_category' => $wgRequest->getVal('suggest_category'), 'st_suggested' => wfTimestampNow(), 'st_notify' => $email, 'st_source' => 'req', 'st_key' => generateSearchKey($title), 'st_group' => rand(0, 4)));
         } elseif ($email) {
             // request exists lets add the user's email to the list of notifications
             $existing = $dbr->selectField('suggested_titles', array('st_notify'), array('st_title' => $s->getDBKey()));
             if ($existing) {
                 $email = "{$existing}, {$email}";
             }
             $dbw->update('suggested_titles', array('st_notify' => $email), array('st_title' => $s->getDBKey()));
         }
         $wgOut->addHTML('<style type="text/css" media="all">/*<![CDATA[*/ @import "' . wfGetPad('/extensions/min/f/extensions/wikihow/suggestedtopics.css?rev=') . WH_SITEREV . '"; /*]]>*/</style>');
         $wgOut->addHTML(wfMsg("suggest_confirmation_owl", $s->getFullURL(), $s->getText()));
         return;
     }
     $wgOut->setHTMLTitle('Requested Topics - wikiHow');
     $wgOut->setRobotPolicy('noindex,nofollow');
     $wgOut->addHTML('<style type="text/css" media="all">/*<![CDATA[*/ @import "' . wfGetPad('/extensions/min/f/extensions/wikihow/suggestedtopics.css?rev=') . WH_SITEREV . '"; /*]]>*/</style>');
     $wgOut->addHTML(wfMsg('suggest_sub_header'));
     $wgOut->addHTML("<form action='/Special:RequestTopic' method='POST' onSubmit='return checkSTForm();' name='suggest_topic_form'>");
     $wgOut->addScript('<script type="text/javascript" src="' . wfGetPad('/extensions/min/f/extensions/wikihow/suggestedtopics.js?rev=') . WH_SITEREV . '"></script>');
     $wgOut->addScript("<script type='text/javascript'/>var gSelectCat = '" . wfMsg('suggest_please_select_cat') . "';\n\t\tvar gEnterTitle = '" . wfMsg('suggest_please_enter_title') . "';\n\t\tvar gEnterEmail  = '" . wfMsg('suggest_please_enter_email') . "';\n\t</script>");
     $fc = new FancyCaptcha();
     $cats = $this->getCategoryOptions();
     $wgOut->addHTML(wfMsg('suggest_input_form', $cats, $fc->getForm(), $pass_captcha ? "" : wfMsg('suggest_captcha_failed'), $wgUser->getEmail()));
     //$wgOut->addHTML(wfMsg('suggest_notifications_form', $wgUser->getEmail()));
     //$wgOut->addHTML(wfMsg('suggest_submit_buttons'));
     $wgOut->addHTML("</form>");
 }
Пример #2
0
 function execute($par)
 {
     global $wgUser, $wgOut, $wgLang, $wgTitle, $wgMemc, $wgDBname, $wgScriptPath;
     global $wgRequest, $wgSitename, $wgLanguageCode;
     global $wgScript;
     $fname = "wfSpecialEmailLink";
     if ($wgRequest->getVal('fromajax')) {
         $wgOut->setArticleBodyOnly(true);
     }
     $this->setHeaders();
     $me = Title::makeTitle(NS_SPECIAL, "EmailLink");
     $action = $me->getFullURL();
     $fc = new FancyCaptcha();
     $pass_captcha = true;
     $name = $from = $r1 = $r2 = $r3 = $m = "";
     if ($wgRequest->wasPosted()) {
         $pass_captcha = $fc->passCaptcha();
         $email = $wgRequest->getVal("email");
         $name = $wgRequest->getVal("name");
         $recipient1 = $wgRequest->getVal('recipient1');
         $recipient2 = $wgRequest->getVal('recipient2');
         $recipient3 = $wgRequest->getVal('recipient3');
         if (preg_match("@kittens683\\@aol.com@", $recipient1) || preg_match("@kittens683\\@aol.com@", $recipient2) || preg_match("@kittens683\\@aol.com@", $recipient3)) {
             return;
         }
         $message = $wgRequest->getVal('message');
     }
     if (!$wgRequest->wasPosted() || !$pass_captcha) {
         if ($wgUser->getID() > 0 && !$wgUser->canSendEmail()) {
             $userEmail = $wgUser->getEmail();
             // If there is no verification time stamp and no email on record, show initial message to have a user input a valid email address
             if (empty($userEmail)) {
                 wfDebug("User can't send.\n");
                 $wgOut->errorpage("mailnologin", "mailnologintext");
             } else {
                 // When user does have an email on record, but has not verified it yet
                 wfDebug("User can't send without verification.\n");
                 $wgOut->errorpage("mailnologin", "mailnotverified");
             }
             return;
         }
         $titleKey = isset($par) ? $par : $wgRequest->getVal('target');
         if ($titleKey == "") {
             $wgOut->addHTML("<br/></br><font color=red>" . wfMsg('error-no-title') . "</font>");
             return;
         }
         $titleObj = Title::newFromURL($titleKey);
         if (!$titleObj) {
             $titleObj = Title::newFromURL(urldecode($titleKey));
         }
         if (!$titleObj || $titleObj->getArticleID() < 0) {
             $wgOut->addHTML("<br/></br><font color=red>" . wfMsg('error-article-not-found') . "</font>");
             return;
         } else {
             $titleKey = $titleObj->getDBKey();
         }
         $articleObj = new Article($titleObj);
         $subject = $titleObj->getText();
         $titleText = $titleObj->getText();
         if (WikihowArticleEditor::articleIsWikiHow($articleObj)) {
             $subject = wfMsg('howto', $subject);
             $titleText = wfMsg('howto', $titleText);
         }
         $subject = wfMsg('wikihow-article-subject', $subject);
         if ($titleObj->getText() == wfMsg('mainpage')) {
             $subject = wfMsg('wikihow-article-subject-main-page');
         }
         // add the form HTML
         $article_title = wfMsg('article') . ":";
         if ($titleObj->getNamespace() == NS_ARTICLE_REQUEST) {
             $wgOut->addHTML("<br/><br/>" . wfMsg('know-someone-answer-topic-request'));
             $article_title = wfMsg('topic-requested') . ":";
         }
         if ($titleObj->getNamespace() != NS_MAIN && $titleObj->getNamespace() != NS_ARTICLE_REQUEST && $titleObj->getNamespace() != NS_PROJECT) {
             $wgOut->errorPage('emaillink', 'emaillink_invalidpage');
             return;
         }
         if ($titleObj->getText() == "Books For Africa") {
             $message = wfMsg('friend-sends-article-email-africa-body');
         }
         $titleKey = urlencode($titleKey);
         $token = $this->getToken1();
         $wgOut->addHTML("\n<link type='text/css' rel='stylesheet' href='" . wfGetPad('/extensions/wikihow/common/jquery-ui-themes/jquery-ui.css?rev=' . WH_SITEREV) . "' />\n<form id=\"emaillink\" method=\"post\" action=\"{$action}\">\n<input type=\"hidden\" name=\"target\" value=\"{$titleKey}\">\n<input type=\"hidden\" name=\"token\" value=\"{$token}\">\n<table border=\"0\">\n<tr>\n<td valign=\"top\" colspan=\"1\" class='mw-label'>{$article_title}</td>\n<td valign=\"top\" colspan=\"2\">{$titleText}</td>\n</tr>\n");
         if ($wgUser->getID() <= 0) {
             $wgOut->addHTML("\n<tr>\n<td valign=\"top\" colspan=\"1\" class='mw-label'>" . wfMsg('your-name') . ":</td>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"name\" value=\"{$name}\" class='input_med'></td>\n</tr>\n<tr>\n<td valign=\"top\" colspan=\"1\" class='mw-label'>" . wfMsg('your-email') . ":</td>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"email\" value=\"{$email}\" class='input_med'></td>\n</tr>");
         }
         $wgOut->addHTML("\n<tr>\n<td valign=\"top\" width=\"300px\" colspan=\"1\" rowspan='3' class='mw-label'>" . wfMsg('recipient-emails') . ":</td>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"recipient1\" value=\"{$recipient1}\" class='input_med'></td>\n</tr>\n<tr>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"recipient2\" value=\"{$recipient2}\" class='input_med'></td>\n</tr>\n<tr>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"recipient3\" value=\"{$recipient3}\" class='input_med'></td>\n</tr>\n<!--<tr>\n<td valign=\"top\" colspan=\"1\">" . wfMsg('emailsubject') . ":</td>\n<td valign=\"top\" colspan=\"2\"><input type=text size=\"40\" name=\"subject\" value=\"{$subject}\" class='input_med'></td>\n</tr>-->\n<tr>\n<td colspan=\"1\" valign=\"top\" class='mw-label'>" . wfMsg('emailmessage') . ":</td>\n<td colspan=\"2\"><TEXTAREA rows=\"5\" cols=\"55\" name=\"message\">{$message}</TEXTAREA></td>\n</tr>\n<tr>\n<TD>&nbsp;</TD>\n<TD colspan=\"2\"><br/>\n" . wfMsgWikiHTML('emaillink_captcha') . "\n" . ($pass_captcha ? "" : "<br><br/><font color='red'>Sorry, that phrase was incorrect, try again.</font><br/><br/>") . "\n" . $fc->getForm('') . "\n</TD>\n</tr>\n<tr>\n<TD>&nbsp;</TD>\n<TD colspan=\"2\"><br/>\n<input type='submit' name=\"wpEmaiLinkSubmit\" value=\"" . wfMsg('submit') . "\" class=\"button primary\" />\n</td>\n</tr>\n<tr>\n<TD colspan=\"3\">\n<br/><br/>\n" . wfMsg('share-message-three-friends') . "\n</TD>\n</TR>\n\n");
         // do this if the user isn't logged in
         $wgOut->addHTML("</table> </form>");
     } else {
         if ($wgUser->pingLimiter('emailfriend')) {
             $wgOut->rateLimited();
             wfProfileOut("{$fname}-checks");
             wfProfileOut($fname);
             return false;
         }
         $usertoken = $wgRequest->getVal('token');
         $token1 = $this->getToken1();
         $token2 = $this->getToken2();
         if ($usertoken != $token1 && $usertoken != $token2) {
             $this->reject();
             echo "token {$usertoken} {$token1} {$token2}\n";
             exit;
             return;
         }
         // check referrer
         $good_referer = Title::makeTitle(NS_SPECIAL, "EmailLink")->getFullURL();
         $referer = $_SERVER["HTTP_REFERER"];
         if (strpos($refer, $good_referer) != 0) {
             $this->reject();
             echo "referrer bad\n";
             exit;
         }
         // this is a post, accept the POST data and create the Request article
         $recipient1 = $_POST['recipient1'];
         $recipient2 = $_POST['recipient2'];
         $recipient3 = $_POST['recipient3'];
         $titleKey = $_POST['target'];
         $message = $_POST['message'];
         if ($titleKey == "Books-For-Africa") {
             $titleKey = "wikiHow:" . $titleKey;
         }
         $titleKey = urldecode($titleKey);
         $titleObj = Title::newFromDBKey($titleKey);
         if ($titleObj->getArticleID() <= 0) {
             $this->reject();
             echo "no article id\n";
             exit;
         }
         $dbkey = $titleObj->getDBKey();
         $articleObj = new Article($titleObj);
         $subject = $titleObj->getText();
         $how_to = $subject;
         if (WikihowArticleEditor::articleIsWikiHow($articleObj)) {
             $subject = wfMsg("howto", $subject);
         }
         $how_to = $subject;
         if ($titleObj->getNamespace() == NS_ARTICLE_REQUEST) {
             $subject = wfMsg('subject-requested-howto') . ": " . wfMsg("howto", $subject);
         } else {
             if ($titleObj->getNamespace() == NS_PROJECT) {
                 $subject = wfMsg('friend-sends-article-email-africa-subject');
             } else {
                 $subject = wfMsg('wikihow-article-subject', $subject);
             }
         }
         if ($titleObj->getNamespace() != NS_MAIN && $titleObj->getNamespace() != NS_ARTICLE_REQUEST && $titleObj->getNamespace() != NS_PROJECT) {
             $wgOut->errorPage('emaillink', 'emaillink_invalidpage');
             return;
         }
         // for the body of the email
         $titleText = $titleObj->getText();
         if ($titleText != wfMsg('mainpage')) {
             $summary = Article::getSection($articleObj->getContent(true), 0);
             // trip out all MW and HTML tags
             $summary = ereg_replace("<.*>", "", $summary);
             $summary = ereg_replace("\\[\\[.*\\]\\]", "", $summary);
             $summary = ereg_replace("\\{\\{.*\\}\\}", "", $summary);
         }
         $url = $titleObj->getFullURL();
         $from_name = "";
         $validEmail = "";
         if ($wgUser->getID() > 0) {
             $from_name = $wgUser->getName();
             $real_name = $wgUser->getRealName();
             if ($real_name != "") {
                 $from_name = $real_name;
             }
             $email = $wgUser->getEmail();
             if ($email != "") {
                 $validEmail = $email;
                 $from_name .= "<{$email}>";
             } else {
                 $from_name .= "<*****@*****.**>";
             }
         } else {
             $email = $wgRequest->getVal("email");
             $name = $wgRequest->getVal("name");
             if ($email == "") {
                 $email = "*****@*****.**";
             } else {
                 $validEmail = $email;
             }
             $from_name = "{$name} <{$email}>";
         }
         if (strpos($email, "\n") !== false || strpos($recipient1, "\n") !== false || strpos($recipient2, "\n") !== false || strpos($recipient3, "\n") !== false || strpos($title, "\n") !== false) {
             echo "reciep\n";
             exit;
             $this->reject();
             return;
         }
         $r_array = array();
         $num_recipients = 0;
         if ($recipient1 != "") {
             $num_recipients++;
             $x = split(";", $recipient1);
             $r_array[] = $x[0];
         }
         if ($recipient2 != "") {
             $num_recipients++;
             $x = split(";", $recipient2);
             $r_array[] = $x[0];
         }
         if ($recipient3 != "") {
             $num_recipients++;
             $x = split(";", $recipient3);
             $r_array[] = $x[0];
         }
         if ($titleObj->getNamespace() == NS_PROJECT) {
             $r_array[] = '*****@*****.**';
         }
         if ($validEmail != "" && !in_array($validEmail, $r_array)) {
             $num_recipients++;
             $r_array[] = $validEmail;
         }
         if ($titleObj->getNamespace() == NS_ARTICLE_REQUEST) {
             $body = "{$message}\n\n----------------\n\n\t" . wfMsg('article-request-email', $how_to, "http://www.wikihow.com/index.php?title2={$dbkey}&action=easy&requested={$dbkey}", "http://www.wikihow.com/Request:{$dbkey}", "http://www.wikihow.com/" . wfMsg('writers-guide-url'), "http://www.wikihow.com/" . wfMsg('about-wikihow-url') . "");
         } else {
             if ($titleObj->getText() == wfMsg('mainpage')) {
                 $body = "{$message}\n\n----------------\n\n\t" . wfMsg('friend-sends-article-email-main-page') . "\n\n\t";
             } else {
                 if ($titleObj->getNamespace() == NS_PROJECT) {
                     $body = "{$message}";
                 } else {
                     $body = "{$message}\n\n----------------\n\n" . wfMsg('friend-sends-article-email', $how_to, $summary, $url) . "\n\n\t";
                 }
             }
         }
         $from = new MailAddress($email);
         foreach ($r_array as $address) {
             $address = preg_replace("@,.*@", "", $address);
             $to = new MailAddress($address);
             $sbody = $body;
             if ($address == $validEmail) {
                 $sbody = wfMsg('copy-email-from-yourself') . "\n\n" . $sbody;
             }
             if (!userMailer($to, $from, $subject, $sbody, false)) {
                 //echo "got an en error\n";
             }
         }
         SiteStatsUpdate::addLinksEmailed($num_recipients);
         $this->thanks();
     }
 }
Пример #3
0
 function getForm($new_window = false, $title = null, $return_result = false)
 {
     global $wgUser, $wgTitle, $wgRequest;
     wfLoadExtensionMessages('Postcomment');
     $postbtn = " class= 'button primary' ";
     $prevbtn = " class= 'button secondary' ";
     if ($title == null) {
         $title = $wgTitle;
     }
     if (!$title->userCanEdit()) {
         return;
     }
     if (!$wgUser->isAllowed('edit')) {
         return;
     }
     $action = $wgRequest->getVal('action');
     // just for talk pages
     if (!$title->isTalkPage() || $action != '' || $wgRequest->getVal('diff', null) != null) {
         return;
     }
     if (!$title->userCanEdit()) {
         echo wfMsg('postcomment_discussionprotected');
         return;
     }
     $sk = $wgUser->getSkin();
     $user_str = "";
     if ($wgUser->getID() == 0) {
         $user_str = wfMsg('postcomment_notloggedin');
     } else {
         $link = $sk->makeLinkObj($wgUser->getUserPage(), $wgUser->getName());
         $user_str = wfMsg('postcomment_youareloggedinas', $link);
     }
     $msg = wfMsg('postcomment_addcommentdiscussionpage');
     $previewPage = Title::makeTitle(NS_SPECIAL, "PostcommentPreview");
     $me = Title::makeTitle(NS_SPECIAL, "Postcomment");
     $pc = Title::newFromText("Postcomment", NS_SPECIAL);
     if ($title->getNamespace() == NS_USER_TALK) {
         $msg = wfMsg('postcomment_leaveamessagefor', $title->getText());
     }
     $id = rand(0, 10000);
     $newpage = $wgTitle->getArticleId() == 0 ? "true" : "false";
     $fc = null;
     $pass_captcha = true;
     if ($wgUser->getID() == 0) {
         $fc = new FancyCaptcha();
     }
     $result = "<div id='postcomment_newmsg_{$id}'></div>\n\t\t\t<script type='text/javascript'>\n\t\t\t\tvar gPreviewText = \"" . wfMsg('postcomment_generatingpreview') . "\";\n\t\t\t\tvar gPreviewURL = \"{$previewPage->getFullURL()}\";\n\t\t\t\tvar gPostURL = \"{$me->getFullURL()}\";\n\t\t\t\tvar gPreviewMsg = \"" . wfMsg('postcomment_previewmessage') . "\";\n\t\t\t\tvar gNewpage = {$newpage};\n\t\t\t</script>\n\t\t\t<script type='text/javascript' src='" . wfGetPad('/extensions/min/f/extensions/Postcomment/postcomment.js?') . WH_SITEREV . "'></script>\n\t\t\t<div id='postcomment_progress_{$id}' style='display:none;'><center><img src='" . wfGetPad('/extensions/Postcomment/upload.gif') . "' alt='Sending...'/></center></div>\n\t\t\t";
     //XXCHANGED Vu added for google analytics tracking gat
     if ($wgTitle->getNamespace() == NS_TALK) {
         $result .= "<form id=\"gatDiscussionPost\" name=\"postcommentForm_{$id}\" method=\"post\" action=\"{$pc->getFullURL()}\" " . ($new_window ? "target='_blank'" : "") . " onsubmit='return postcommentPublish(\"postcomment_newmsg_{$id}\", document.postcommentForm_{$id});'>";
     } else {
         if ($wgTitle->getNamespace() == NS_USER_TALK) {
             $result .= "<form id=\"gatTalkPost\" name=\"postcommentForm_{$id}\" method=\"post\" action=\"{$pc->getFullURL()}\" " . ($new_window ? "target='_blank'" : "") . " onsubmit='return postcommentPublish(\"postcomment_newmsg_{$id}\", document.postcommentForm_{$id});'>";
         } else {
             $result .= "<form name=\"postcommentForm_{$id}\" method=\"post\" action=\"{$pc->getFullURL()}\" " . ($new_window ? "target='_blank'" : "") . " onsubmit='return postcommentPublish(\"postcomment_newmsg_{$id}\", document.postcommentForm_{$id});'>";
         }
     }
     $avatar = Avatar::getAvatarURL($wgUser->getName());
     if ($avatar) {
         $user_icon = 'background-image: url(' . $avatar . ')';
     }
     $result .= "\n\t\t\t<input name=\"target\" type=\"hidden\" value=\"" . htmlspecialchars($title->getPrefixedDBkey()) . "\"/>\n\t        <a name=\"postcomment\"></a>\n\t        <a name=\"post\"></a>\n\t\t\t<textarea class=\"postcommentForm_textarea\" tabindex='3' rows='15' cols='100' name=\"comment_text_{$id}\" id=\"comment_text_{$id}\" placeholder=\"{$msg}\" style=\"{$user_icon}\"></textarea>\n\t        <div class=\"postcommentForm_buttons\">\n\t\t\t\t<input tabindex='4' type='button' onclick='postcommentPreview(\"{$id}\");' value=\"" . wfMsg('postcomment_preview') . "\" {$prevbtn} />\n\t\t\t\t<input tabindex='5' type='submit' value=\"" . wfMsg('postcomment_post') . "\" id='postcommentbutton_{$id}' {$postbtn} />\n\t\t\t</div>\n\t\t\t<div class=\"postcommentForm_details\">\n\t\t\t\t{$user_str}\n\t\t\t\t" . ($pass_captcha ? "" : "<br><br/><font color='red'>Sorry, that phrase was incorrect, try again.</font><br/><br/>") . "\n\t\t\t\t" . ($fc == null ? "" : $fc->getForm('')) . "\n\t\t\t</div>\n\t        </form>\n\t\t\t<div id='postcomment_preview_{$id}' class='postcomment_preview'></div>\n\t\t\t";
     //add anchor link
     $return = '<a name="leave-a-message" id="leave-a-message"></a>' . $return;
     if ($return_result) {
         return $result;
     } else {
         echo $result;
     }
 }
Пример #4
0
 /**
  * create wiki form
  *
  * @access public
  *
  * @param $subpage Mixed: subpage of SpecialPage
  */
 public function createWikiForm()
 {
     global $wgOut, $wgUser, $wgExtensionsPath, $wgScriptPath, $wgStylePath;
     global $wgRequest, $wgDBname, $wgMemc;
     wfProfileIn(__METHOD__);
     #-
     $aTopLanguages = explode(',', wfMsg('autocreatewiki-language-top-list'));
     $aLanguages = wfGetFixedLanguageNames();
     asort($aLanguages);
     #-
     $hubs = WikiFactoryHub::getInstance();
     $aCategories = $hubs->getCategories();
     #--
     $params = $this->fixSessionKeys();
     if (empty($params) && empty($this->mPosted)) {
         $ip = $wgRequest->getIP();
         $key = wfMemcKey(self::CACHE_LOGIN_KEY, $wgDBname, $ip);
         $params = $wgMemc->get($key);
     }
     $fancyCaptcha = new FancyCaptcha();
     $wgOut->addScript("<link rel=\"stylesheet\" type=\"text/css\" href=\"{$wgStylePath}/common/form.css\" />");
     $wgOut->addScript("<link rel=\"stylesheet\" type=\"text/css\" href=\"{$wgStylePath}/common/wikia_ui/tabs.css\" />");
     // RT #19245
     $wgOut->addStyle("common/form.ie7.css", '', 'IE 7');
     $wgOut->addScript("<script type=\"text/javascript\" src=\"{$wgStylePath}/common/form.js\"></script>");
     /**
      * run template
      */
     $this->mAction = $wgRequest->getVal("action", false);
     if ($this->mAction == "reload") {
         $params['wiki-name'] = $wgRequest->getVal('wiki-name', false);
         $params['wiki-domain'] = $wgRequest->getVal('wiki-domain', false);
         $params['wiki-category'] = $wgRequest->getVal('wiki-category', false);
         $params['wiki-language'] = $wgRequest->getVal('wiki-language', $wgUser->getOption('language'));
         $params['wiki-type'] = $wgRequest->getVal('wiki-type', false);
     }
     $oTmpl = new EasyTemplate(dirname(__FILE__) . "/templates/");
     $oTmpl->set_vars(array("subDomain" => $this->mDefSubdomain, "wgUser" => $wgUser, "wgExtensionsPath" => $wgExtensionsPath, "aLanguages" => $aLanguages, "aTopLanguages" => $aTopLanguages, "aCategories" => $aCategories, "wgScriptPath" => $wgScriptPath, "mTitle" => $this->mTitle, "mType" => $this->mType, "mLanguage" => $this->mLang, "mPostedErrors" => $this->mPostedErrors, "wgStylePath" => $wgStylePath, "captchaForm" => $fancyCaptcha->getForm(), "params" => $params, "subName" => $this->mDefSitename, "defaultDomain" => self::DEFAULT_DOMAIN, "mDomains" => $this->mDomains, "mSitenames" => $this->mSitenames));
     $wgOut->setRobotpolicy('noindex,nofollow');
     $wgOut->setArticleRelated(false);
     $wgOut->addHtml($oTmpl->render("create-wiki-form"));
     wfProfileOut(__METHOD__);
     return;
 }