<?php
/**
* XS2:
*
* This file is developed by Solutecs, LLC for the purpose of the company
* and is provided together with XS2 Framework as and inherent part of the
* system. This file can be used on the terms of License Agreement.
*
* +7 (495) 585-0833 / 13 Rusakovskaya street, Moscow 107140 Russia
*
* @link http://www.solutecs.com
* @copyright ©1998-2007 Solutecs, LLC
* @package XS2-MODCOM
* @subpackage proc-forum
* @version 1.XX
*/
xs2Fetch(array('mod'=>'forum', 'obj'=>'config', 'met'=>'date'));
xs2Fetch(array('mod'=>'forum', 'obj'=>'user', 'met'=>'lib'));
xs2Fetch(array('mod'=>'forum', 'obj'=>'config', 'met'=>'vars'));
xs2Fetch(array('mod'=>'forum', 'obj'=>'config', 'met'=>'parse'));
$section = xs2GetNode(array('NodId'=>$_THE['PARAMS'][0]));
$threads = array();
if (!$section['NodId'] || 'section'!=$section['NType']) {
$section = xs2GetNodes(array('NType'=>'section'));
if(count($section)>0)
$section = $section[0];
}
if ($section['NodId']>0) {
$threads = xs2GetChildren(array('ParId'=>$section['NodId'],
'NType'=>'thread'));
if(count($GLOBALS['VisitedThreads'])) {
foreach($threads as $key=>$thread) {
$threads[$key]['isVisited'] = in_array($thread['NodId'], $GLOBALS['VisitedThreads']);
}
}
}
$_HTML->assign('section', $section);
$_HTML->assign('threads', $threads);
?>
|
|