the error about "no news items" is not here now
grettings
echo "<input type='text' id='subject' name='subject' size='60' maxlength='100' value='$subject' /></td></tr>
$sel_category = 9;
include_once (XOOPS_ROOT_PATH."/class/xoopstree.php");
$xt = new XoopsTree('xoops_mydownloads_cat', "cid", "pid");
$categories = $xt->getAllChildId($sel_category);
$categorystring = implode(',', $categories);
$categorystring = $sel_category.",".$categories;
$result = $xoopsDB->query("SELECT lid, cid, title, date, hits FROM xoops_mydownloads_downloads WHERE cid IN ($categorystring) ORDER BY {$options[0]} DESC", $options[1], 0);
include_once (XOOPS_ROOT_PATH."/class/xoopstree.php");
$xt = new XoopsTree('xoops_mydownloads_cat', "cid", "pid");
$categories = $xt->getAllChildId(9);
$categorystring = "(";
foreach ($categories as $key => $categoryid) {
if ($key != 0) { //Only comma-separate subsequent categories
$categorystring .= ", ";
}
$categorystring .= $categoryid;
}
$categorystring = implode(',', $categories);
$result = $xoopsDB->query("SELECT lid, cid, title, date, hits FROM xoops_mydownloads_downloads WHERE cid IN ($categorystring) ORDER BY {$options[0]} DESC", $options[1], 0);