root/dev/common/invtype.php @ 254

Revision 254, 0.8 KB (checked in by exi, 15 years ago)

Merging 242:253 branch into dev

Line 
1<?php
2if (!$id = intval($_GET['id']))
3{
4    $page = new Page('Error');
5    $page->setContent('No valid ID specified.');
6    $page->generate();
7    exit;
8}
9include_once('common/includes/class.dogma.php');
10
11$item = new dogma($id);
12
13if (!$item->isValid())
14{
15    $page = new Page('Error');
16    $page->setContent('This ID is not a valid dogma ID.');
17    $page->generate();
18    exit;
19}
20
21$page = new Page('Item details - '.$item->get('typeName'));
22
23#$dump = var_export($item, true);
24#$smarty->assign('dump', $dump);
25$smarty->assign_by_ref('item', $item);
26
27if ($item->get('itt_cat') == 6)
28{
29    $html = $smarty->fetch(get_tpl('invtype_ship'));
30}
31else
32{
33    $html = $smarty->fetch(get_tpl('invtype_item'));
34}
35$page->setContent($html);
36$page->generate();
37return;
38?>
Note: See TracBrowser for help on using the browser.