本文整理汇总了PHP中Tags::getTree方法的典型用法代码示例。如果您正苦于以下问题:PHP Tags::getTree方法的具体用法?PHP Tags::getTree怎么用?PHP Tags::getTree使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Tags
的用法示例。
在下文中一共展示了Tags::getTree方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: explode
// Cannot use new style of parameters here (function is called by a custom-attribute event - and therefore does not know about named parameters)
// Split PageID and SiteID
$data = explode('-', $this->reponsedata['name']->yg_id);
// Set the new name
if ($tagMgr->setName($data[0], $this->reponsedata['name']->value) === false) {
$koala->alert($itext['TXT_ERROR_ACCESS_DENIED']);
} else {
$jsQueue->add($data[0], HISTORYTYPE_TAG, 'OBJECT_CHANGE', sGuiUS(), 'tag', NULL, NULL, $this->reponsedata['name']->yg_id, 'name', $this->reponsedata['name']->value);
$jsQueue->add($data[0], HISTORYTYPE_TAG, 'OBJECT_CHANGE', sGuiUS(), 'page', NULL, NULL, $this->reponsedata['name']->yg_id, 'name', $this->reponsedata['name']->value);
$jsQueue->add($data[0], HISTORYTYPE_TAG, 'REFRESH_WINDOW', sGuiUS(), 'name');
}
break;
case 'tagSelectNode':
$node = $this->params['node'];
$wid = $this->params['wid'];
$root_node = $tagMgr->getTree(NULL, 0);
// Tags
// 1 = rsub
// 2 = rread
// 3 = rdelete
// 4 = parent -> rsub & rwrite
// 5 = parent -> rsub & rwrite
// 6 = rdelete
$buttons = array();
// Get Parents
$parentid = $tagMgr->getParents($node);
$parentid = $parentid[0][0]['ID'];
// Check rights
$rread = $tagMgr->permissions->checkInternal(sUserMgr()->getCurrentUserID(), $node, "RREAD");
$rwrite = $tagMgr->permissions->checkInternal(sUserMgr()->getCurrentUserID(), $node, "RWRITE");
$rsub = $tagMgr->permissions->checkInternal(sUserMgr()->getCurrentUserID(), $node, "RSUB");
示例2: Icons
<?php
header('Content-type: text/xml');
$newsite = (int) $this->request->parameters['site'];
$newpage = (int) $this->request->parameters['page'];
$node_id = $this->request->parameters['nid'];
if ($node_id) {
$node_id = str_replace('tag_', '', $node_id);
}
$maxlevels = 1;
if ($newsite != 0) {
$site = $newsite;
}
$icons = new Icons();
$tagMgr = new Tags();
$tree = $tagMgr->getTree($node_id, 2);
$yo = $tagMgr->tree->nest($tree);
$xml_tree = array();
$tree_id = 0;
$tree_level = 0;
$action = $this->request->parameters['action'];
if ($action == 'addtag') {
$noclick = 'noclick';
} else {
$noclick = '';
}
if ($node_id) {
$root_id = 'tag_' . $yo[$node_id]['ID'];
$root_name = htmlspecialchars($yo[$node_id]['NAME']);
$root_cststyle = '';
} else {