Release plat/al core v1.1.13
[platal.git] / plugins / function.select_db_table.php
index 80f20a0..bc83d95 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /***************************************************************************
- *  Copyright (C) 2003-2010 Polytechnique.org                              *
+ *  Copyright (C) 2003-2011 Polytechnique.org                              *
  *  http://opensource.polytechnique.org/                                   *
  *                                                                         *
  *  This program is free software; you can redistribute it and/or modify   *
@@ -56,8 +56,8 @@ function select_options($table, $value, $field, $pad, $where, $join, $group)
     return $html;
 }
 
-function smarty_function_select_db_table($params, &$smarty) {
-    if (empty($params['table']) || empty($params['valeur'])) {
+function smarty_function_select_db_table($params, $smarty) {
+    if (empty($params['table']) || !array_key_exists('valeur', $params)) {
         return;
     }
     if (empty($params['champ'])) {
@@ -74,5 +74,5 @@ function smarty_function_select_db_table($params, &$smarty) {
                           $params['where'], $params['join'], $params['group']);
 }
 
-// vim:set et sw=4 sts=4 sws=4 foldmethod=marker enc=utf-8:
+// vim:set et sw=4 sts=4 sws=4 foldmethod=marker fenc=utf-8:
 ?>