Exemplo n.º 1
0
echo $aInt->lang("general", "apirestriction");
echo "</td><td class=\"fieldarea\">";
echo "<s";
echo "elect name=\"apiallowedips[]\" id=\"apiallowedips\" size=\"3\" style=\"min-width:200px;\" multiple>";
$whitelistedips = unserialize($CONFIG['APIAllowedIPs']);
foreach ($whitelistedips as $whitelist) {
    echo "<option value=" . $whitelist['ip'] . ">" . $whitelist['ip'] . " - " . $whitelist['note'] . "</option>";
}
echo "</select> ";
echo $aInt->lang("general", "apirestrictioninfo");
echo "<br /><a href=\"javascript:;\" onClick=\"showDialog('addapiip')\"><img src=\"images/icons/add.png\" align=\"absmiddle\" border=\"0\" /> ";
echo $aInt->lang("general", "addip");
echo "</a> <a href=\"#\" id=\"removeapiip\"><img src=\"images/icons/delete.png\" align=\"absmiddle\" border=\"0\" /> ";
echo $aInt->lang("general", "removeselected");
echo "</a></td></tr>\n";
$token_manager =& getTokenManager();
echo $token_manager->generateAdminConfigurationHTMLRows($aInt);
echo "\n</table>\n\n  </div>\n</div>\n<!-- Social -->\n<div id=\"tab10box\" class=\"tabbox\">\n  <div id=\"tab_content\">\n\n<table class=\"form\" width=\"100%\" border=\"0\" cellspacing=\"2\" cellpadding=\"3\">\n<tr><td class=\"fieldlabel\">";
echo $aInt->lang("general", "twitterint");
echo "</td><td class=\"fieldarea\"><input type=\"text\" name=\"twitterusername\" size=\"20\" value=\"";
echo $CONFIG['TwitterUsername'];
echo "\" /> ";
echo $aInt->lang("general", "twitterintinfo");
echo "</td></tr>\n<tr><td class=\"fieldlabel\">";
echo $aInt->lang("general", "twitterannouncementstweet");
echo "</td><td class=\"fieldarea\"><label><input type=\"checkbox\" name=\"announcementstweet\"";
if ($CONFIG['AnnouncementsTweet']) {
    echo " checked";
}
echo " /> ";
echo $aInt->lang("general", "twitterannouncementstweetinfo");
Exemplo n.º 2
0
 /**
  * Initialisation of class
  *
  * @return WHMCS_Init
  */
 public function init()
 {
     spl_autoload_register(array($this, "load_class"));
     $_GET = $this->sanitize_input_vars($_GET);
     $_POST = $this->sanitize_input_vars($_POST);
     $_REQUEST = $this->sanitize_input_vars($_REQUEST);
     $_SERVER = $this->sanitize_input_vars($_SERVER);
     $_COOKIE = $this->sanitize_input_vars($_COOKIE);
     foreach ($this->danger_vars as $var) {
         if (isset($_REQUEST[$var]) || isset($_FILES[$var])) {
             exit("Unauthorized request");
             continue;
         }
     }
     $this->load_input();
     $this->clean_input();
     $this->register_globals();
     if (!$this->load_config_file()) {
         exit("<div style=\"border: 1px dashed #cc0000;font-family:Tahoma;background-color:#FBEEEB;width:100%;padding:10px;color:#cc0000;\"><strong>Welcome to WHMCS 5.2.15 FULL DECODED && NULLED BY MTIMER!</strong><a></a><br>Before you can begin using WHMCS you need to perform the installation procedure. <a href=\"" . (file_exists("install/install.php") ? "" : "../") . "install/install.php\" style=\"color:#000;\">Click here to begin ...</a><form action=\"https://www.paypal.com/cgi-bin/webscr\" method=\"post\" target=\"_blank\" style=\"margin-top:10px;margin-bottom:5px;\"><input type=\"hidden\" name=\"cmd\" value=\"_s-xclick\"><input type=\"hidden\" name=\"hosted_button_id\" value=\"N3T56B5LHAGBS\"><input type=\"image\" src=\"https://www.paypal.com/en_US/i/btn/btn_donate_LG.gif\" border=\"0\" name=\"submit\" alt=\"Donate to get updates lifetime!\" style=\"margin-bottom:-5px;\"><p style=\"display:inline;margin-left:10px;\"> to get v5.2.16 & updates lifetime via email. Be fair and support this project. It doesn't cost much :) ~</p></form></div>");
     }
     if (!$this->database_connect()) {
         exit("<div style=\"border: 1px dashed #cc0000;font-family:Tahoma;background-color:#FBEEEB;width:100%;padding:10px;color:#cc0000;\"><strong>Critical Error</strong><br>Could not connect to the database</div>");
     }
     $this->sanitize_db_vars();
     global $CONFIG;
     global $PHP_SELF;
     global $remote_ip;
     $PHP_SELF = $_SERVER['PHP_SELF'] = $_SERVER['SCRIPT_NAME'];
     $remote_ip = $this->remote_ip = $this->get_user_ip();
     $CONFIG = $this->load_config_vars();
     if ($this->enforce_ip_bans()) {
         redir("", $CONFIG['SystemURL'] . "/banned.php");
     }
     $instanceid = $this->getWHMCSInstanceID();
     if (!$instanceid) {
         $instanceid = $this->createWHMCSInstanceID();
     }
     $session = new WHMCS_Session();
     $session->create($instanceid);
     $token_manager =& getTokenManager($this);
     $token_manager->conditionallySetToken();
     if (isset($_SESSION['Language'])) {
         $this->set_client_language($_SESSION['Language'], 1);
     }
     if (isset($_REQUEST['systpl'])) {
         $_SESSION['Template'] = $_REQUEST['systpl'];
     }
     if (isset($_REQUEST['carttpl'])) {
         $_SESSION['OrderFormTemplate'] = $_REQUEST['carttpl'];
     }
     $this->validate_templates();
     $this->validate_admin_auth();
     $this->validate_client_auth();
     return $this;
 }
Exemplo n.º 3
0
 function check_token($namespace = "WHMCS.default")
 {
     $token_manager =& getTokenManager();
     return $token_manager->checkToken($namespace);
 }