From: x2000habouzit Date: Tue, 2 Nov 2004 07:30:47 +0000 (+0000) Subject: closes #163 X-Git-Tag: xorg/old~1096 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=007bd43e82d1c98bc2b73a4bc41bef56f5174a9d;p=platal.git closes #163 --- diff --git a/htdocs/search.php b/htdocs/search.php index b689c36..fc542e6 100644 --- a/htdocs/search.php +++ b/htdocs/search.php @@ -18,7 +18,7 @@ * Foundation, Inc., * * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * *************************************************************************** - $Id: search.php,v 1.39 2004-11-02 07:28:34 x2000habouzit Exp $ + $Id: search.php,v 1.40 2004-11-02 07:30:47 x2000habouzit Exp $ ***************************************************************************/ require("auto.prepend.inc.php"); @@ -59,6 +59,11 @@ if (array_key_exists('rechercher', $_REQUEST)) { { new ThrowError('Recherche trop générale.'); } + + if (!logged() && empty($_REQUEST['prenom']) && empty($_REQUEST['nom'])) + { + new ThrowError('Il faut au moins entrer un nom ou un prenom.'); + } $offset = new NumericSField('offset'); $sql = 'SELECT SQL_CALC_FOUND_ROWS