root/original/common/contracts.php

Revision 1, 1.0 KB (checked in by andrewgunn, 14 years ago)

Added original EVE-Killboard.net source code.

Line 
1<?
2  require_once( "class.page.php" );
3  require_once( "class.contract.php" );
4  require_once( "class.box.php" );
5 
6  $page = new Page( "Contracts" );
7
8  switch( $_GET['view'] ) {
9    case "":
10      $activelist = new ContractList();
11      $activelist->setCampaigns( false );
12      $activelist->setActive( "yes" );
13      $page->setTitle( "Active contracts" );
14      $table = new ContractListTable( $activelist );
15      $html .= $table->generate();
16    break;
17    case "past":
18      $pastlist = new ContractList();
19      $pastlist->setCampaigns( false );
20      $pastlist->setActive( "no" );
21      $page->setTitle( "Past contracts" );
22      $table = new ContractListTable( $pastlist );
23      $html .= $table->generate();
24    break;
25  }
26
27  $menubox = new MenuBox();
28  $menubox->addOption( "Active contracts", "?a=contracts" );
29  $menubox->addOption( "Past contracts", "?a=contracts&view=past" );
30
31  $page->addContext( $menubox->generate() );
32  $page->setContent( $html );
33  $page->generate();
34?>
Note: See TracBrowser for help on using the browser.