[BUGFIX] Reduce spacing CGL violations in /typo3/
[Packages/TYPO3.CMS.git] / typo3 / show_item.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
6 * All rights reserved
7 *
8 * This script is part of the TYPO3 project. The TYPO3 project is
9 * free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * The GNU General Public License can be found at
15 * http://www.gnu.org/copyleft/gpl.html.
16 * A copy is found in the textfile GPL.txt and important notices to the license
17 * from the author is found in LICENSE.txt distributed with these scripts.
18 *
19 *
20 * This script is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
24 *
25 * This copyright notice MUST APPEAR in all copies of the script!
26 ***************************************************************/
27 /**
28 * Shows information about a database or file item
29 *
30 * Revised for TYPO3 3.7 May/2004 by Kasper Skårhøj
31 *
32 * @author Kasper Skårhøj <kasperYYYY@typo3.com>
33 */
34
35
36 $GLOBALS['BACK_PATH'] = '';
37 require_once('init.php');
38 require_once('template.php');
39
40
41
42
43
44
45
46
47
48
49
50
51 /**
52 * Extension of transfer data class
53 *
54 * @author Kasper Skårhøj <kasperYYYY@typo3.com>
55 * @package TYPO3
56 * @subpackage core
57 */
58 class transferData extends t3lib_transferData {
59
60 var $formname = 'loadform';
61 var $loading = 1;
62
63 // Extra for show_item.php:
64 var $theRecord = Array();
65
66 /**
67 * Register item function.
68 *
69 * @param string Table name
70 * @param integer Record uid
71 * @param string Field name
72 * @param string Content string.
73 * @return void
74 */
75 function regItem($table, $id, $field, $content) {
76 t3lib_div::loadTCA($table);
77 $config = $GLOBALS['TCA'][$table]['columns'][$field]['config'];
78 switch($config['type']) {
79 case 'input':
80 if (isset($config['checkbox']) && $content == $config['checkbox']) {
81 $content = '';
82 break;
83 }
84 if (t3lib_div::inList($config['eval'],'date')) {
85 $content = Date($GLOBALS['TYPO3_CONF_VARS']['SYS']['ddmmyy'], $content);
86 }
87 break;
88 case 'group':
89 break;
90 case 'select':
91 break;
92 }
93 $this->theRecord[$field]=$content;
94 }
95 }
96
97
98
99
100
101
102
103
104
105
106
107 /**
108 * Script Class for showing information about an item.
109 *
110 * @author Kasper Skårhøj <kasperYYYY@typo3.com>
111 * @package TYPO3
112 * @subpackage core
113 */
114 class SC_show_item {
115
116 // GET vars:
117 var $table; // Record table (or filename)
118 var $uid; // Record uid (or '' when filename)
119
120 // Internal, static:
121 var $perms_clause; // Page select clause
122 var $access; // If TRUE, access to element is granted
123 var $type; // Which type of element: "file" or "db"
124 var $doc; // Document Template Object
125
126 // Internal, dynamic:
127 var $content; // Content Accumulation
128 var $pageinfo; // For type "db": Set to page record of the parent page of the item set (if type="db")
129 var $row; // For type "db": The database record row.
130
131 /**
132 * The fileObject if present
133 *
134 * @var t3lib_file_AbstractFile
135 */
136 protected $fileObject;
137
138 /**
139 * The folder obejct if present
140 *
141 * @var t3lib_file_Folder
142 */
143 protected $folderObject;
144
145 /**
146 * Initialization of the class
147 * Will determine if table/uid GET vars are database record or a file and if the user has access to view information about the item.
148 *
149 * @return void
150 */
151 function init() {
152 // Setting input variables.
153 $this->table = t3lib_div::_GET('table');
154 $this->uid = t3lib_div::_GET('uid');
155
156 // Initialize:
157 $this->perms_clause = $GLOBALS['BE_USER']->getPagePermsClause(1);
158 $this->access = FALSE; // Set to TRUE if there is access to the record / file.
159 $this->type = ''; // Sets the type, "db" or "file". If blank, nothing can be shown.
160
161 // Checking if the $table value is really a table and if the user has access to it.
162 if (isset($GLOBALS['TCA'][$this->table])) {
163 t3lib_div::loadTCA($this->table);
164 $this->type = 'db';
165 $this->uid = intval($this->uid);
166
167 // Check permissions and uid value:
168 if ($this->uid && $GLOBALS['BE_USER']->check('tables_select',$this->table)) {
169 if ((string)$this->table == 'pages') {
170 $this->pageinfo = t3lib_BEfunc::readPageAccess($this->uid,$this->perms_clause);
171 $this->access = is_array($this->pageinfo) ? 1 : 0;
172 $this->row = $this->pageinfo;
173 } else {
174 $this->row = t3lib_BEfunc::getRecordWSOL($this->table, $this->uid);
175 if ($this->row) {
176 $this->pageinfo = t3lib_BEfunc::readPageAccess($this->row['pid'],$this->perms_clause);
177 $this->access = is_array($this->pageinfo) ? 1 : 0;
178 }
179 }
180
181 $treatData = t3lib_div::makeInstance('t3lib_transferData');
182 $treatData->renderRecord($this->table, $this->uid, 0, $this->row);
183 $cRow = $treatData->theRecord;
184 }
185 } elseif ($this->table == '_FILE' || $this->table == '_FOLDER' || $this->table == 'sys_file') {
186 $fileOrFolderObject = t3lib_file_Factory::getInstance()->retrieveFileOrFolderObject($this->uid);
187
188 if ($fileOrFolderObject instanceof t3lib_file_Folder) {
189 $this->folderObject = $fileOrFolderObject;
190 $this->access = $this->folderObject->checkActionPermission('read');
191 $this->type = 'folder';
192 } else {
193 $this->fileObject = $fileOrFolderObject;
194 $this->access = $this->fileObject->checkActionPermission('read');
195 $this->type = 'file';
196 $this->table = 'sys_file';
197 t3lib_div::loadTCA($this->table);
198 try {
199 $this->row = t3lib_BEfunc::getRecordWSOL($this->table, $this->fileObject->getUid());
200 } catch (Exception $e) {
201 $this->row = array();
202 }
203
204
205 }
206 }
207
208 // Initialize document template object:
209 $this->doc = t3lib_div::makeInstance('template');
210 $this->doc->backPath = $GLOBALS['BACK_PATH'];
211
212 // Starting the page by creating page header stuff:
213 $this->content.=$this->doc->startPage($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.viewItem'));
214 $this->content.='<h3 class="t3-row-header">' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.viewItem') . '</h3>';
215 $this->content.=$this->doc->spacer(5);
216 }
217
218 /**
219 * Main function. Will generate the information to display for the item set internally.
220 *
221 * @return void
222 */
223 function main() {
224
225 if ($this->access) {
226 $returnLink = t3lib_div::sanitizeLocalUrl(t3lib_div::_GP('returnUrl'));
227 $returnLinkTag = $returnLink ? '<a href="' . $returnLink . '" class="typo3-goBack">' : '<a href="#" onclick="window.close();">';
228 // render type by user func
229 $typeRendered = FALSE;
230 if (is_array ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['typo3/show_item.php']['typeRendering'])) {
231 foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['typo3/show_item.php']['typeRendering'] as $classRef) {
232 $typeRenderObj = t3lib_div::getUserObj($classRef);
233 if (is_object($typeRenderObj) && method_exists($typeRenderObj, 'isValid') && method_exists($typeRenderObj, 'render')) {
234 if ($typeRenderObj->isValid($this->type, $this)) {
235 $this->content .= $typeRenderObj->render($this->type, $this);
236 $typeRendered = TRUE;
237 break;
238 }
239 }
240 }
241 }
242
243 // if type was not rendered use default rendering functions
244 if(!$typeRendered) {
245 // Branch out based on type:
246 switch ($this->type) {
247 case 'db':
248 $this->renderDBInfo();
249 break;
250 case 'file':
251 $this->renderFileInfo($returnLinkTag);
252 break;
253 case 'folder':
254 // @todo: implement a info about a folder
255 break;
256 }
257 }
258
259 // If return Url is set, output link to go back:
260 if (t3lib_div::sanitizeLocalUrl(t3lib_div::_GP('returnUrl'))) {
261 $this->content = $this->doc->section('',$returnLinkTag.'<strong>'.$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:labels.goBack',1).'</strong></a><br /><br />').$this->content;
262
263 $this->content .= $this->doc->section('','<br />'.$returnLinkTag.'<strong>'.$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:labels.goBack',1).'</strong></a>');
264 }
265 }
266 }
267
268 /**
269 * Main function. Will generate the information to display for the item set internally.
270 *
271 * @return void
272 */
273 function renderDBInfo() {
274
275 // Print header, path etc:
276 $code = $this->doc->getHeader($this->table,$this->row,$this->pageinfo['_thePath'],1).'<br />';
277 $this->content.= $this->doc->section('',$code);
278
279 // Initialize variables:
280 $tableRows = Array();
281 $i = 0;
282
283 // Traverse the list of fields to display for the record:
284 $fieldList = t3lib_div::trimExplode(',', $GLOBALS['TCA'][$this->table]['interface']['showRecordFieldList'], 1);
285 foreach ($fieldList as $name) {
286 $name = trim($name);
287 if ($GLOBALS['TCA'][$this->table]['columns'][$name]) {
288 if (!$GLOBALS['TCA'][$this->table]['columns'][$name]['exclude'] || $GLOBALS['BE_USER']->check('non_exclude_fields', $this->table . ':' . $name)) {
289 $i++;
290 $tableRows[] = '
291 <tr>
292 <td class="t3-col-header">' . $GLOBALS['LANG']->sL(t3lib_BEfunc::getItemLabel($this->table, $name), 1) . '</td>
293 <td>' . htmlspecialchars(t3lib_BEfunc::getProcessedValue($this->table, $name, $this->row[$name], 0, 0, FALSE, $this->row['uid'])) . '</td>
294 </tr>';
295 }
296 }
297 }
298
299 // Create table from the information:
300 $tableCode = '
301 <table border="0" cellpadding="0" cellspacing="0" id="typo3-showitem" class="t3-table-info">
302 '.implode('',$tableRows).'
303 </table>';
304 $this->content.=$this->doc->section('',$tableCode);
305
306 // Add path and table information in the bottom:
307 $code = '';
308 $code .= $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:labels.path') . ': ' . t3lib_div::fixed_lgd_cs($this->pageinfo['_thePath'], -48) . '<br />';
309 $code .= $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:labels.table') . ': ' . $GLOBALS['LANG']->sL($GLOBALS['TCA'][$this->table]['ctrl']['title']) . ' (' . $this->table . ') - UID: ' . $this->uid . '<br />';
310 $this->content.= $this->doc->section('', $code);
311
312 // References:
313 $this->content.= $this->doc->section($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.referencesToThisItem'),$this->makeRef($this->table,$this->row['uid']));
314
315 // References:
316 $this->content.= $this->doc->section($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.referencesFromThisItem'),$this->makeRefFrom($this->table,$this->row['uid']));
317 }
318
319 /**
320 * Main function. Will generate the information to display for the item set internally.
321 *
322 * @param string $returnLinkTag <a> tag closing/returning.
323 * @return void
324 */
325 function renderFileInfo($returnLinkTag) {
326 $fileExtension = $this->fileObject->getExtension();
327 // Setting header:
328 $code = '<div class="fileInfoContainer">'
329 . t3lib_iconWorks::getSpriteIconForFile($fileExtension) . '<strong>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.file', TRUE) . ':</strong> ' . $this->fileObject->getName()
330 . '&nbsp;&nbsp;'
331 . '<strong>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.filesize') . ':</strong> '
332 . t3lib_div::formatSize($this->fileObject->getSize())
333 . '</div>
334 ';
335 $this->content .= $this->doc->section('', $code);
336 $this->content .= $this->doc->divider(2);
337
338 // If the file was an image...
339 // @todo: add this check in the domain model in some kind of way, or in the processing folder
340 if (t3lib_div::inList($GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext'], $fileExtension)) {
341 // @todo: find a way to make getimagesize part of the t3lib_file object
342 $imgInfo = @getimagesize($this->fileObject->getForLocalProcessing(FALSE));
343
344 $thumbUrl = $this->fileObject->process(
345 t3lib_file_ProcessedFile::CONTEXT_IMAGEPREVIEW,
346 array('width' => '150m', 'height' => '150m')
347 )->getPublicUrl(TRUE);
348 $code = '<div class="fileInfoContainer fileDimensions">'
349 . '<strong>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.dimensions')
350 . ':</strong> ' . $imgInfo[0] . 'x' . $imgInfo[1] . ' '
351 . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.pixels') . '</div>';
352 $code .= '<br />
353 <div align="center">' . $returnLinkTag . '<img src="' . $thumbUrl . '" alt="' . htmlspecialchars(trim($this->fileObject->getName())) . '" title="' . htmlspecialchars(trim($this->fileObject->getName())) . '" /></a></div>';
354 $this->content .= $this->doc->section('', $code);
355 } elseif ($fileExtension == 'ttf') {
356 $thumbUrl = $this->fileObject->process(
357 t3lib_file_ProcessedFile::CONTEXT_IMAGEPREVIEW,
358 array('width' => '530m', 'height' => '600m')
359 )->getPublicUrl(TRUE);
360 $thumb = '<br />
361 <div align="center">' . $returnLinkTag . '<img src="' . $thumbUrl . '" border="0" title="' . htmlspecialchars(trim($this->fileObject->getName())) . '" alt="" /></a></div>';
362 $this->content .= $this->doc->section('', $thumb);
363 }
364
365 // Initialize variables:
366 $tableRows = array();
367 $i = 0;
368
369 // Traverse the list of fields to display for the record:
370 $fieldList = t3lib_div::trimExplode(',', $GLOBALS['TCA'][$this->table]['interface']['showRecordFieldList'], TRUE);
371 foreach ($fieldList as $name) {
372 $name = trim($name);
373 if ($GLOBALS['TCA'][$this->table]['columns'][$name]) {
374 if (!$GLOBALS['TCA'][$this->table]['columns'][$name]['exclude'] || $GLOBALS['BE_USER']->check('non_exclude_fields', $this->table . ':' . $name)) {
375 $i++;
376 $tableRows[] = '
377 <tr>
378 <td class="t3-col-header">' . $GLOBALS['LANG']->sL(t3lib_BEfunc::getItemLabel($this->table, $name), 1) . '</td>
379 <td>' . htmlspecialchars(t3lib_BEfunc::getProcessedValue($this->table, $name, $this->row[$name], 0, 0, FALSE, $this->row['uid'])) . '</td>
380 </tr>';
381 }
382 }
383 }
384
385 // Create table from the information:
386 $tableCode = '
387 <table border="0" cellpadding="0" cellspacing="0" id="typo3-showitem" class="t3-table-info">
388 ' . implode('', $tableRows) . '
389 </table>';
390 $this->content .= $this->doc->section('', $tableCode);
391
392
393 if ($this->fileObject->isIndexed()) {
394 // References:
395 $this->content .= $this->doc->section($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.referencesToThisItem'), $this->makeRef('_FILE', $this->fileObject));
396 }
397 }
398
399 /**
400 * End page and print content
401 *
402 * @return void
403 */
404 function printContent() {
405 $this->content.= $this->doc->endPage();
406 $this->content = $this->doc->insertStylesAndJS($this->content);
407 echo $this->content;
408 }
409
410 /**
411 * Get table field name
412 *
413 * @param string $tableName Table name
414 * @param string $fieldName Field name
415 * @return string Field name
416 */
417 public function getFieldName($tableName, $fieldName) {
418 t3lib_div::loadTCA($tableName);
419 if ($GLOBALS['TCA'][$tableName]['columns'][$fieldName]['label'] !== NULL) {
420 $field = $GLOBALS['LANG']->sL($GLOBALS['TCA'][$tableName]['columns'][$fieldName]['label']);
421 if (trim($field) === '') {
422 $field = $fieldName;
423 }
424 } else {
425 $field = $fieldName;
426 }
427 return $field;
428 }
429
430 /**
431 * Make reference display
432 *
433 * @param string $table Table name
434 * @param string $ref Filename or uid
435 * @return string HTML
436 */
437 function makeRef($table, $ref) {
438
439 if ($table === '_FILE') {
440 // Look up the path:
441 $rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
442 '*',
443 'sys_file_reference',
444 'uid_local=' . $ref->getUid()
445 );
446 } else {
447 // Look up the path:
448 $rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
449 '*',
450 'sys_refindex',
451 'ref_table=' . $GLOBALS['TYPO3_DB']->fullQuoteStr($table,'sys_refindex') . ' AND ref_uid=' . intval($ref) .
452 ' AND deleted=0'
453 );
454 }
455 // Compile information for title tag:
456 $infoData = array();
457 if (count($rows)) {
458 $infoData[] = '<tr class="t3-row-header">' .
459 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.table') . '</td>' .
460 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.title') . '</td>' .
461 '<td>[uid]</td>' .
462 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.field') . '</td>' .
463 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.flexpointer') . '</td>' .
464 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.softrefKey') . '</td>' .
465 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.sorting') . '</td>' .
466 '</tr>';
467 }
468 foreach($rows as $row) {
469 if($table === '_FILE') {
470 $row = $this->mapFileReferenceOnRefIndex($row);
471 }
472 $record = t3lib_BEfunc::getRecord($row['tablename'], $row['recuid']);
473 $infoData[] = '<tr class="bgColor4">' .
474 '<td>' . $GLOBALS['LANG']->sL($GLOBALS['TCA'][$row['tablename']]['ctrl']['title'], TRUE) . '</td>' .
475 '<td>' . t3lib_BEfunc::getRecordTitle($row['tablename'], $record, TRUE) . '</td>' .
476 '<td><span title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_common.xlf:page') . ': ' .
477 htmlspecialchars(t3lib_BEfunc::getRecordTitle('pages', t3lib_BEfunc::getRecord('pages', $record['pid']))) .
478 " (uid=" . $record['pid'] . ')">' . $record['uid'] . '</span></td>' .
479 '<td>' . htmlspecialchars($this->getFieldName($row['tablename'], $row['field'])) . '</td>' .
480 '<td>' . htmlspecialchars($row['flexpointer']) . '</td>' .
481 '<td>' . htmlspecialchars($row['softref_key']) . '</td>' .
482 '<td>' . htmlspecialchars($row['sorting']) . '</td>' .
483 '</tr>';
484 }
485
486 return count($infoData)
487 ? '<table border="0" cellpadding="0" cellspacing="0" class="typo3-dblist">' . implode('', $infoData) . '</table>'
488 : '';
489 }
490
491 /**
492 * Maps results from the fal file reference table on the
493 * structure of the normal reference index table.
494 *
495 * @param array $fileReference
496 * @return array
497 */
498 protected function mapFileReferenceOnRefIndex(array $fileReference) {
499 return array(
500 'recuid' => $fileReference['uid_foreign'],
501 'tablename' => $fileReference['tablenames'],
502 'field' => $fileReference['fieldname'],
503 'flexpointer' => '',
504 'softref_key' => '',
505 'sorting' => $fileReference['sorting_foreign']
506 );
507 }
508
509 /**
510 * Make reference display (what this elements points to)
511 *
512 * @param $table string Table name
513 * @param $ref string Filename or uid
514 * @return string HTML
515 */
516 function makeRefFrom($table, $ref) {
517
518 // Look up the path:
519 $rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(
520 '*',
521 'sys_refindex',
522 'tablename=' . $GLOBALS['TYPO3_DB']->fullQuoteStr($table, 'sys_refindex') .
523 ' AND recuid=' . intval($ref)
524 );
525
526 // Compile information for title tag:
527 $infoData = array();
528 if (count($rows)) {
529 $infoData[] = '<tr class="t3-row-header">' .
530 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.field') . '</td>' .
531 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.flexpointer') . '</td>' .
532 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.softrefKey') . '</td>' .
533 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.sorting') . '</td>' .
534 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.refTable') . '</td>' .
535 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.refUid') . '</td>' .
536 '<td>' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:show_item.php.refString') . '</td>' .
537 '</tr>';
538 }
539 foreach($rows as $row) {
540 $infoData[] = '<tr class="bgColor4">' .
541 '<td>' . htmlspecialchars($this->getFieldName($table, $row['field'])) . '</td>' .
542 '<td>' . htmlspecialchars($row['flexpointer']) . '</td>' .
543 '<td>' . htmlspecialchars($row['softref_key']) . '</td>' .
544 '<td>' . htmlspecialchars($row['sorting']) . '</td>' .
545 '<td>' . $GLOBALS['LANG']->sL($GLOBALS['TCA'][$row['ref_table']]['ctrl']['title'], TRUE) . '</td>' .
546 '<td>' . htmlspecialchars($row['ref_uid']) . '</td>' .
547 '<td>' . htmlspecialchars($row['ref_string']) . '</td>' .
548 '</tr>';
549 }
550
551 return count($infoData)
552 ? '<table border="0" cellpadding="0" cellspacing="0" class="typo3-dblist">' . implode('', $infoData) . '</table>'
553 : '';
554 }
555 }
556
557 // Make instance:
558 $SOBE = t3lib_div::makeInstance('SC_show_item');
559 $SOBE->init();
560 $SOBE->main();
561 $SOBE->printContent();
562
563 ?>