Exemplo n.º 1
0
 public static function db_get_random_article($array_random_number)
 {
     foreach ($array_random_number as $id_random) {
         $res_sql[] = App::DB()->query_pdo("SELECT * FROM test_articles WHERE id= '" . $id_random . "'", "Evengyl\\module\\Articles");
     }
     return $res_sql;
 }
Exemplo n.º 2
0
 public function db_get_current_sub_categ()
 {
     //on détermine l'option a envoyer pour la requète préparée, ici on envoie l'ID
     $options = array(':id' => $_GET['id_sub_categ']);
     $current_sub_categ = \Evengyl\db\App::DB()->prepare_pdo("SELECT name FROM test_sub_category WHERE id = :id", $options, "Evengyl\\module\\Breadcrumb", true);
     return $current_sub_categ;
 }
 public static function db_get_name_current_subcateg($id_sub_categ)
 {
     return App::DB()->query_pdo("SELECT name AS name_sub_categ FROM test_sub_category WHERE id = '" . $id_sub_categ . "'", "");
 }