From: niekt0 Date: Wed, 28 Sep 2011 22:12:32 +0000 (+0200) Subject: warnings fix X-Git-Url: https://git.harvie.cz/?a=commitdiff_plain;h=68839d5d9431c2d07e3f40c6a5faa46dc880c414;p=mirrors%2FKyberia-bloodline.git warnings fix --- diff --git a/wwwroot/backend/mysql/backend.inc b/wwwroot/backend/mysql/backend.inc index 0f66b8d..bd765af 100644 --- a/wwwroot/backend/mysql/backend.inc +++ b/wwwroot/backend/mysql/backend.inc @@ -541,7 +541,7 @@ public static function logout() { // getNodesByType -// +// XXX // Secure // returns xxx @@ -576,10 +576,11 @@ public static function getNodesByType($vector,$user_id,$type,$orderby,$offset,$l // getLinkedNodes -// +// XXX +// Secure // returns XXX -function getLinkedNodes($node_id,$orderby,$offset,$listing_amount) { +public static function getLinkedNodes($node_id,$orderby,$offset,$listing_amount) { global $db; if ((!is_numeric($node_id)) diff --git a/wwwroot/inc/smarty/node_methodz/function.get_linked_nodes.php b/wwwroot/inc/smarty/node_methodz/function.get_linked_nodes.php index ad44bac..9a846e4 100644 --- a/wwwroot/inc/smarty/node_methodz/function.get_linked_nodes.php +++ b/wwwroot/inc/smarty/node_methodz/function.get_linked_nodes.php @@ -8,8 +8,8 @@ function smarty_function_get_linked_nodes($params,&$smarty) { elseif (is_numeric($params['listing_amount'])) $listing_amount=$params['listing_amount']; else $listing_amount=DEFAULT_LISTING_AMOUNT; - if (is_numeric($params['offset'])) $offset=$params['offset']; - elseif (is_numeric($_POST['offset'])) $offset=$_POST['offset']; + if (isset($params['offset']) && is_numeric($params['offset'])) $offset=$params['offset']; + elseif (isset($_POST['offset']) && is_numeric($_POST['offset'])) $offset=$_POST['offset']; else $offset=0; if (isset($params['node_id'])) {