$tpl->assign( $asssigns ) ; //$tpl->display( 'db:'.$mydirname.'_admin_category.html' ) ; break; case 'modTopic': $template = 'bulletin_modtopic.html'; $BTopic = new BulletinTopic( $mydirname , $_GET['topic_id'] ) ; $topics_array = XoopsLists :: getImgListAsArray( $xoopsModuleConfig['topicon_path'] ); xoops_cp_header(); include dirname(__FILE__).'/mymenu.php' ; $images = array(); foreach($topics_array as $v){ $images[] = array('image' => htmlspecialchars($v), 'option' => $BTopic->topic_imgurl() ? 'selected="selected"' : ''); } //ob_start(); //$BTopic->makeTopicSelBox( 1, $BTopic->topic_pid(), 'topic_pid' ); //$topicselbox = ob_get_contents(); //ob_end_clean(); $topicselbox = $BTopic->makeTopicSelBox( true , $BTopic->topic_pid() , 'topic_pid' ) ; $asssigns = array( 'gticket_hidden' => $xoopsGTicket->getTicketHtml( __LINE__ , 1800 , 'bulletin_admin') , 'images' => $images, 'topic_id' => $BTopic->topic_id(), 'topic_pid' => $BTopic->topic_pid(), 'topic_title' => $BTopic->topic_title('E'), 'topic_imgurl' => $BTopic->topic_imgurl(), 'topic_imgdir' => str_replace(XOOPS_ROOT_PATH,XOOPS_URL,$xoopsModuleConfig['topicon_path']),
//ob_end_clean(); $topicselbox = $BTopic->makeTopicSelBox(true, 0, 'topic_pid'); $topicselbox2 = $BTopic->makeTopicSelBox(); $asssigns = array('gticket_hidden' => $xoopsGTicket->getTicketHtml(__LINE__, 1800, 'bulletin_admin'), 'images' => $images, 'topics_exists' => $topics_exists, 'topicselbox' => $topicselbox, 'topicselbox2' => $topicselbox2); $tpl->assign($asssigns); //$tpl->display( 'db:'.$mydirname.'_admin_category.html' ) ; break; case 'modTopic': $template = 'bulletin_modtopic.html'; $BTopic = new BulletinTopic($mydirname, $_GET['topic_id']); $topics_array = XoopsLists::getImgListAsArray($xoopsModuleConfig['topicon_path']); xoops_cp_header(); include dirname(__FILE__) . '/mymenu.php'; $images = array(); foreach ($topics_array as $v) { $images[] = array('image' => htmlspecialchars($v), 'option' => $BTopic->topic_imgurl() ? 'selected="selected"' : ''); } //ob_start(); //$BTopic->makeTopicSelBox( 1, $BTopic->topic_pid(), 'topic_pid' ); //$topicselbox = ob_get_contents(); //ob_end_clean(); $topicselbox = $BTopic->makeTopicSelBox(true, $BTopic->topic_pid(), 'topic_pid'); $asssigns = array('gticket_hidden' => $xoopsGTicket->getTicketHtml(__LINE__, 1800, 'bulletin_admin'), 'images' => $images, 'topic_id' => $BTopic->topic_id(), 'topic_pid' => $BTopic->topic_pid(), 'topic_title' => $BTopic->topic_title('E'), 'topic_imgurl' => $BTopic->topic_imgurl(), 'topic_imgdir' => str_replace(XOOPS_ROOT_PATH, XOOPS_URL, $xoopsModuleConfig['topicon_path']), 'topicselbox' => $topicselbox); break; case 'addTopic': //ver3.0 if (!$xoopsGTicket->check(true, 'bulletin_admin')) { redirect_header(XOOPS_URL . '/', 3, $xoopsGTicket->getErrors()); } $BTopic = new BulletinTopic($mydirname); $BTopic->setTopicPid($_POST['topic_pid']);
//$BTopic->makeTopicSelBox(); //$topicselbox2 = ob_get_contents(); //ob_end_clean(); $topicselbox = $BTopic->makeTopicSelBox(true, 0, 'topic_pid'); $topicselbox2 = $BTopic->makeTopicSelBox(); $asssigns = array('images' => $images, 'topics_exists' => $topics_exists, 'topicselbox' => $topicselbox, 'topicselbox2' => $topicselbox2); break; case 'modTopic': $template = 'bulletin_modtopic.html'; $BTopic = new BulletinTopic($mydirname, $_GET['topic_id']); $topics_array = XoopsLists::getImgListAsArray($xoopsModuleConfig['topicon_path']); xoops_cp_header(); include dirname(__FILE__) . '/mymenu.php'; $images = array(); foreach ($topics_array as $v) { $images[] = array('image' => htmlspecialchars($v), 'option' => $BTopic->topic_imgurl() ? 'selected="selected"' : ''); } //ob_start(); //$BTopic->makeTopicSelBox( 1, $BTopic->topic_pid(), 'topic_pid' ); //$topicselbox = ob_get_contents(); //ob_end_clean(); $topicselbox = $BTopic->makeTopicSelBox(true, $BTopic->topic_pid(), 'topic_pid'); $asssigns = array('images' => $images, 'topic_id' => $BTopic->topic_id(), 'topic_pid' => $BTopic->topic_pid(), 'topic_title' => $BTopic->topic_title('E'), 'topic_imgurl' => $BTopic->topic_imgurl(), 'topic_imgdir' => str_replace(XOOPS_ROOT_PATH, XOOPS_URL, $xoopsModuleConfig['topicon_path']), 'topicselbox' => $topicselbox); break; case 'addTopic': $BTopic = new BulletinTopic($mydirname); $BTopic->setTopicPid($_POST['topic_pid']); if (empty($_POST['topic_title'])) { redirect_header("index.php?op=topicsmanager", 2, _AM_ERRORTOPICNAME); } $BTopic->setTopicTitle($_POST['topic_title']);