Skip to content

Instantly share code, notes, and snippets.

@medyo
Created June 23, 2015 00:25

Revisions

  1. medyo created this gist Jun 23, 2015.
    14 changes: 14 additions & 0 deletions etudiant.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    public function etudiantExistant($ca,$cin,$cne)
    {
    $q = $this->db->prepare('SELECT count(*) FROM licence WHERE ca = :ca AND cin = :cin AND cne = :cne ');
    $q->bindValue(':ca', $ca);
    $q->bindValue(':cin', $cin);
    $q->bindValue(':cne', $cne);
    $q->execute();
    $number_of_rows = $result->fetchColumn();
    if ($number_of_rows > 0){
    return true;
    }else{
    return false;
    }
    }