Commit 98e5cc1e authored by Clement GAUDUCHEAU's avatar Clement GAUDUCHEAU
Browse files

recherche d'auteurs frequents effectués

parent 830763a9
class AuteursFrequents{
private $connexion;
public function __construct(){
$this->connexion=new PDO("mysql:host=".HOST."; dbname=".BD, LOGIN, PASSWORD, array(PDO::MYSQL_ATTR_INIT_COMMAND=>"SET NAMES utf8"));
}catch(PDOException $e){
public function incrementerNbRecherche($auteur){
$request="UPDATE `auteurs` SET nbRecherche=nbRecherche+1 WHERE nom_auteur like ?";
public function get10Auteurs(){
$request="select nom_auteur from auteurs where nbRecherche>0 order by nbRecherche desc LIMIT 0,8";
return $result;
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment