$indent_html = str_repeat('  ', (int) $index['depth']);
    if (isset($index['child_count']) && $index['child_count'] != 0) {
        $select_label = sprintf(' %s ( %u )', $title, $index['child_count']);
    } else {
        $select_label = sprintf(' %s ', $title);
    }
    $index['indent_html'] = $indent_html;
    $index['select_label'] = $textutil->html_special_chars($select_label);
}
$index = array();
xnp_get_index($xnpsid, $xid, $index);
$indexTree = genSameAreaIndexTree($xnpsid, $uid, $index);
array_walk($indexTree, 'genSelectLabels');
//public index tree set
$public_index = array('open_level' => OL_PUBLIC);
$publicindexTree = genSameAreaIndexTree($xnpsid, $uid, $public_index);
$len = count($publicindexTree);
for ($i = 0; $i < $len; $i++) {
    if (!isset($item_type_id)) {
        $item_type_id = null;
        //Notice undefined variable
    }
}
array_walk($publicindexTree, 'genSelectLabels');
// escape error message
$err_mes = array();
foreach ($error_messages as $mes) {
    $err_mes[] = $textutil->html_special_chars($mes);
}
$xoopsTpl->assign('updown_options', array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9, 10 => 10));
$xoopsTpl->assign('childCount', count($childIndexes));
Exemplo n.º 2
0
    $title = $index['titles'][DEFAULT_INDEX_TITLE_OFFSET];
    $indent_html = str_repeat('&nbsp;&nbsp;', (int) $index['depth']);
    if (isset($index['child_count']) && $index['child_count'] != 0) {
        $select_label = sprintf(' %s ( %u )', $title, $index['child_count']);
    } else {
        $select_label = sprintf(' %s ', $title);
    }
    $index['indent_html'] = $indent_html;
    $index['select_label'] = $textutil->html_special_chars($select_label);
}
// display of 'add to public'
if ($op == '' || $op == 'download') {
    // Display only 'Binder -> Binders'. Display 'Not Binder -> Public not Binders'.
    include_once 'include/gentree.php';
    $index = array('open_level' => OL_PUBLIC);
    $indexTree = genSameAreaIndexTree($xnpsid, $uid, $index);
    array_walk($indexTree, 'genSelectLabels');
    $xoopsTpl->assign('index_tree', $indexTree);
}
include_once XOOPS_ROOT_PATH . '/modules/' . $itemtype['viewphp'];
eval("\$body = " . $modname . "GetDetailBlock( \$item_id );");
$xoopsTpl->assign('body', $body);
$func = $modname . "GetDownloadConfirmationBlock";
if (function_exists($func)) {
    $xoopsTpl->assign('download_confirmation', $func($item_id, $download_file_id));
} else {
    $xoopsTpl->assign('download_file_id', $download_file_id);
}
$xoonips_module_header = '<link rel="stylesheet" type="text/css" href="style.css" />';
$func = $modname . 'GetHeadMeta';
if (function_exists($func)) {