get_image_link fix
[mirrors/Kyberia-bloodline.git] / wwwroot / inc / smarty / node_methodz / function.get_image_link.php
index a391aa07d0107b67bde9505be0c0ff471d2c9520..ca181f373b8ba98bb8d26deac6cd45aa1d93635c 100644 (file)
@@ -2,6 +2,8 @@
 function smarty_function_get_image_link($params,&$smarty) {
        global $db;
        $id = $params['id'];
+       
+       if (!is_numeric($id)) { return 1;}
        $img = './'.SYSTEM_IMAGES.'/nodes/'.substr($id,0,1)."/".substr($id,1,1)."/$id.gif";
 
        if (file_exists($img)) {
@@ -16,6 +18,7 @@ function smarty_function_get_image_link($params,&$smarty) {
                }
                echo $imglink;
        }
+       return 0;
 }
 
 ?>
This page took 0.121864 seconds and 4 git commands to generate.