$q="select users.*,nodes.* from nodes
left join users on users.user_id=nodes.node_creator where
node_parent='$node_handle' order by node_created $orderby LIMIT $offset,$limit";
- echo $q;
+ #echo $q;
$result=$db->query($q);
while ($result->next()) {
}
+function GetUserSubmissionsChildren($user_id,$limit=23,$offset=0,$orderby='') {
+ global $db;
+
+ $q="select users.*,nodes.* from nodes
+left join users on users.user_id=nodes.node_creator where
+node_creator='$user_id' order by node_created $orderby LIMIT $offset,$limit";
+ //$q="select * from nodes LIMIT 10,10";
+ #echo $q;
+ $result=$db->query($q);
+
+ while ($result->next()) {
+ $array[]=addBase36id($result->getRecord());
+ }
+
+ return $array;
+}
+
function getThreadedChildrenNodes($orderby="desc",$offset=0,$limit=DEFAULT_LISTING_AMOUNT) {
global $db, $error, $node;
$node_handle=$node['node_id'];
}
function getInt($column) { //DEPRECATED!!! Use $this->fetch(); instead!!!
- $this->getString(); //Dynamic typing OMG...
+ $this->getString($column); //Dynamic typing OMG...
}
function getNumRows() { //DEPRECATED!!! Use $this->rowCount(); instead!!!
\r
function smarty_function_get_user_submissions_children($params, &$smarty) {\r
\r
- if (!isset($_SESSION['user_id')\r
+ if (isset($_SESSION['user_id']))\r
$user_id = $_SESSION['user_id'];\r
else\r
return -1;\r
-\r
+/*\r
if (!isset($params['listing_amount']))\r
$listing_amount = DEFAULT_LISTING_AMMOUNT;\r
else\r
$order_by = $params['order_by'];\r
else\r
$order_by = 'node_id';\r
-\r
- $replies=nodes::GetUserSubmissionsChildren($user_id,$listing_ammount,$offset,$order_by);\r
-\r
+*/\r
+ $replies=nodes::GetUserSubmissionsChildren($user_id /*,$listing_ammount,$offset,$order_by*/ );\r
$smarty->assign('get_user_submissions_children', $replies);\r
+\r
}\r
\r
-?>\r