phpDocumentor lodel
[ class tree: lodel ] [ index: lodel ] [ all elements ]

Procedural File: validfunc.php

Source Location: /lodel/scripts/validfunc.php

Page Details

Fichier utilitaire pour gérer la validation des champs

PHP versions 4 et 5

LODEL - Logiciel d'Edition ELectronique.

Copyright (c) 2001-2002, Ghislain Picard, Marin Dacos Copyright (c) 2003, Ghislain Picard, Marin Dacos, Luc Santeramo, Nicolas Nutten, Anne Gentil-Beccot Copyright (c) 2004, Ghislain Picard, Marin Dacos, Luc Santeramo, Anne Gentil-Beccot, Bruno Cénou Copyright (c) 2005, Ghislain Picard, Marin Dacos, Luc Santeramo, Gautier Poupeau, Jean Lamy, Bruno Cénou Copyright (c) 2006, Marin Dacos, Luc Santeramo, Bruno Cénou, Jean Lamy, Mikaël Cixous, Sophie Malafosse

Home page: http://www.lodel.org

E-Mail: lodel@lodel.org

All Rights Reserved

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

Author:  Sophie Malafosse
Author:  Ghislain Picard
Author:  Jean Lamy
Version:  CVS:$Id:
Copyright:  2006, Marin Dacos, Luc Santeramo, Bruno Cénou, Jean Lamy, Mikaël Cixous, Sophie Malafosse
Copyright:  2005, Ghislain Picard, Marin Dacos, Luc Santeramo, Gautier Poupeau, Jean Lamy, Bruno Cénou
Functions
validfield  [line 60]

boolean validfield( &$text, string $type, [string $default = ""], [string $name = ""], [string $usedata = ""], [ $directory = ""], string $&text  )

Validation des champs

Validation des caractères autorisés dans les champs suivant leur type leur nom, et le texte contenu. Par exemple si on a un champ de type email, il faut vérifier que l'adresse mail est bien formée. Idem pour un champ de type url. Cela appliqué à tous les types de champs gérés par Lodel (cf. fichier fieldfunc.php)

Parameters:
string   $&text:  le texte à valider. Passé par référence.
string   $type:  le type du champ à valider.
string   $default:  la valeur par défaut à valider (si le texte est vide). Est vide par défaut
string   $name:  le nom du champ
string   $usedata:  indique si le context utilise le sous tableau data pour stocker les données
   &$text: 
   $directory: 

API Tags:
Return:  true si le champ est valide. false sinon


[ Top ]


Documentation generated on Wed, 29 Aug 2007 14:30:04 +0200 by phpDocumentor 1.4.0a2