예제 #1
0
 public function setVilleNom($vil_nom)
 {
     $vil_nom = removeJavascript($vil_nom);
     if (empty($vil_nom)) {
         throw new ExceptionPerso("Le nom d'une ville ne peut être vide !", ExceptionPerso::ERR_VILLE);
     }
     $this->vil_nom = $vil_nom;
 }
예제 #2
0
 public function setPerPrenom($perPrenom)
 {
     $prenom = removeJavascript($perPrenom);
     if (empty($prenom)) {
         throw new ExceptionPerso("Exception contrôlée, merci de ne pas saisir de javascript !", ExceptionPerso::ERR_PERSONNE);
     }
     $this->per_prenom = $prenom;
 }
예제 #3
0
파일: lib.php 프로젝트: pedru/phplist3
function compressContent($content)
{
    ## this needs loads more testing across systems to be sure
    return $content;
    $content = preg_replace("/\n/", ' ', $content);
    $content = preg_replace("/\r/", '', $content);
    $content = removeJavascript($content);
    $content = stripComments($content);
    ## find some clean way to remove double spacing
    $content = preg_replace("/\t/", ' ', $content);
    while (preg_match('/  /', $content)) {
        $content = preg_replace('/  /', ' ', $content);
    }
    return $content;
}
예제 #4
0
 public function setCitationLibelle($valeur)
 {
     $libelle = removeJavascript($valeur);
     if (empty($libelle)) {
         throw new ExceptionPerso("Le contenu de la blague ne peut-être vide !", ExceptionPerso::ERR_CITATION);
     }
     $this->cit_libelle = $libelle;
 }