Beispiel #1
0
    closetable();
}
//Include as required
if (!empty($op)) {
    $ops = explode("_", $op);
    if (file_exists(INFUSIONS . "user_gold/inc/" . $ops[0] . ".inc.php")) {
        include_once INFUSIONS . "user_gold/inc/" . $ops[0] . ".inc.php";
    }
}
switch ($op) {
    //usergold system (no prefix)
    case "start":
        index();
        break;
    case "list":
        item_display();
        break;
    case "showmembers":
        showmembers();
        break;
        //gamble system
    //gamble system
    case "gamble_menu":
        gamble_menu();
        break;
    case "gamble_gamble":
        gamble_gamble();
        break;
    case "gamble_games":
        //include_once GOLD_INC."games.inc.php";
        gamble_games();
 public function GetOutput($Db)
 {
     global $shpgroups, $owngroups, $interesting, $facmods, $offmods;
     $Assets = new eveApiAssets($Db);
     $full_url = FULL_URL;
     // TODO
     $time_start = microtime_float();
     if (!$Assets->fetch(CHAR_ID, USER_ID, API_KEY, CORP_MODE)) {
         $this->Output = $Assets->Error;
         return false;
     }
     $this->Updated = APITime($Assets);
     $this->Title = "Assets for " . USER_NAME;
     $time_end = microtime_float();
     $time_api = $time_end - $time_start;
     $Db->updateConqStations();
     $result = $Db->selectWhere("invGroups", ['categoryID' => 6], ['groupName', 'groupID']);
     $shpgroups = array();
     if ($result != false) {
         if ($result->rows > 0) {
             foreach ($result->results as $row) {
                 $shpgroups[$row["groupID"]] = $row["groupName"];
             }
         }
     }
     $owngroups = array();
     $hrwidth = 450;
     $start = true;
     $last = "";
     $interesting = "";
     $facmods = 0;
     $offmods = 0;
     $pos_fuels = isset($_GET['posfuels']);
     $xpandall = isset($_GET['xpandall']);
     /*
     if (isset($_GET['query'])) {
     $query = array();
     $pairs = explode(";",$_GET['query']);
     foreach($pairs as $arg) {
     $arg2 = explode(":",$arg);
     
     switch($arg2[0]) {
     case "type": $query[$arg2[1]] = "typeID"; break;
     case "group": $query[$arg2[1]] = "typeID"; break;
     case "cat": $query[$arg2[1]] = "cat"; break;
     }
     }
     }
     */
     $this->Output .= "<table><tr><td  VALIGN=\"top\" >";
     $this->Output .= $Assets->totalCt . " items total in " . count($Assets->assetsByLocation) . " locations<br>";
     if (!$xpandall) {
         $this->Output .= "<a href=\"{$full_url}&view=assets&xpandall\">Expand all entries</a><br>";
     } else {
         $this->Output .= "<a href=\"{$full_url}&view=assets\">Collapse all entries</a><br>";
     }
     $this->Output .= "<br><table class='fancy2'>";
     foreach ($Assets->assetsByLocation as $location => $items) {
         $station = $Db->getLocationNameFromId($location);
         /*
         if ($station == null)
         $station = $item["locationID"];
         */
         if ($pos_fuels) {
             $bad = true;
             foreach ($items as $itemId => $item) {
                 if (contains_pos_fuel($item)) {
                     $bad = false;
                 }
             }
             if ($bad) {
                 continue;
             }
         }
         $this->Output .= "<tr><td style='cursor:pointer;' onclick=\"return toggle_visibility('l{$location}');\"><a href=\"#\" onclick=\"return false\">";
         $this->Output .= "<b>" . $station . "</b></a>" . ($location < 60000000 ? " (in space)" : "") . "</td><td align=right><b>" . count($items) . "&nbsp;item" . (count($items) == 1 ? "" : "s") . "</b>&nbsp;&nbsp;&nbsp;<br></td></tr>";
         $this->Output .= "<tr><td colspan=2><div id=\"l{$location}\" style=\"" . ($xpandall ? "display:block;" : "display:none;") . "\"><br>\n";
         foreach ($items as $itemId => $item) {
             $this->Output .= item_display($station, $itemId, $item);
         }
         $this->Output .= "<br></div></td></tr>\n";
     }
     $this->Output .= "</table></td><td valign=top>";
     $this->Output .= "Significant assets:";
     $this->Output .= "<br><br>";
     if ($interesting != "") {
         $this->Output .= $interesting;
     } else {
         $this->Output .= "&nbsp;Character has no significant assets.<br>";
     }
     $this->Output .= "<br>";
     $namedowngroups = array();
     foreach ($owngroups as $group_id => $cnt) {
         $namedowngroups[$shpgroups[$group_id]] = $cnt;
     }
     ksort($namedowngroups);
     $this->Output .= "&nbsp;Ships by Group:<br><br>";
     $this->Output .= "<table>";
     $this->Output .= "<tr><th>type</th><th># owned</th></tr>";
     foreach ($namedowngroups as $group => $cnt) {
         $this->Output .= "<tr><td>&nbsp;{$group}&nbsp;</td><td>{$cnt}</td></tr>\n";
     }
     $this->Output .= "</table>";
     $this->Output .= "</td></tr></table>";
     $this->Times = getPageTimes($Db, $time_api, microtime_float() - $time_start);
     return true;
 }
Beispiel #3
0
<?php

//this page's purpose is to provide a list where users will be able to contribute item defindexes to have the items whitelisted.
//this whitelist will be used in all parts of the scanner where no prices are available.
//this will allow users to set prices for as-of-yet unpriced items so that the stupid responsibility of doing so will not be exclusively on my shoulders.
include 'php/440_core.php';
include 'php/global_whitelist_core.php';
createHead('Price items!', 440, '<script src="js/as-compiled.js" ></script><link rel="stylesheet" href="css/autoSuggest.css" type="text/css" media="screen">');
echo '<div class="news">This is a page where you can vote on what items you want to see on the scanner.<br>By voting on items, you will change their prices which will make them appear in scans.</div>';
if (isset($_POST['save'])) {
    bwlist_save($_POST);
}
if (isset($_POST['delete'])) {
    bwlist_delete();
}
echo ' <form action="' . $_SERVER['PHP_SELF'] . '" method="POST">', '<input type="text" id=as-input class=as-input autocomplete=off data-autocompleteurl=php/autocomplete.php>', '<input type="submit"></form><br><br>', bwlist_display();
item_display(reset($_POST));
createFooter();