Afficher les annonces adsence sur mon site

jamsom Messages postés 212 Date d'inscription   Statut Membre Dernière intervention   -  
jordane45 Messages postés 30426 Date d'inscription   Statut Modérateur Dernière intervention   -
Bonjour,
j'ai créé un site avec Php, j'ajouter le code des annnoces adsence, mais elles ne s'affichent pas sur les pages
comment résoudre ce problème
mon site est
[URL SUPPRIMÉE PAR LA MODERATION]

2 réponses

  1. jordane45 Messages postés 30426 Date d'inscription   Statut Modérateur Dernière intervention   4 830
     
    Bonjour,

    Il faut que tu nous montres ton code ...
    Sans ça .. impossible de te répondre
    0
    1. jamsom Messages postés 212 Date d'inscription   Statut Membre Dernière intervention  
       
      le code de mon site ou le code de l'annone??
      0
      1. jordane45 Messages postés 30426 Date d'inscription   Statut Modérateur Dernière intervention   4 830 > jamsom Messages postés 212 Date d'inscription   Statut Membre Dernière intervention  
         
        Le code de ton site
        0
  2. jamsom Messages postés 212 Date d'inscription   Statut Membre Dernière intervention  
     
    <html>
    <head>

    <meta charset="utf-8" />
    <link rel="stylesheet" href="styles.css" />

    <script type="text/javascript" src="engine1/jquery.js"></script>
    <title> موقع المعرفة، إقرأ و تعلم واستفذ </title>
    <link rel="shortcut icon" type="image/x-icon" href="images/maaloma.ico" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta property="og:title" content="موقع المعرفة، إقرأ و تعلم واستفذ " />
    <meta property="og:type" content="article" />
    <meta property="og:url" content="http://www.maaloma.net/" />
    <meta property="og:image" content="http://www.maaloma.net/images/ordi.jpg" />

    <link rel="stylesheet" href="http://www.maaloma.net/css/top.css">

    </head>
    <body >

    <div id="bloc_page" > <!-- *************************division principale de la page (bloc page)********************************** -->
    <header>
    <?php include("entete.php"); ?>
    </header>

    <section id="Section3"> <!-- *****************************Section -3-********************************** -->
    <div id="pv"> <!-- *****************************Division -2- Section -3- ********************************** -->
    <div class="bout" dir="rtl"> <a href="http://www.maaloma.net/plusvisite.php" rel="nofollow noopener noreferrer" target="_blank"> الأكثرقراءة:</a></div>

    </div>
    <div id="sld"> <!-- *****************************Division -1- Section -3- ********************************** -->
    <p dir="rtl" align ="center" id= "lien2">المواضيــــــــــع الجديدة:</p>
    <?php include("slider1.php"); ?>
    </div>
    <div id="Div2Section3"> <!-- *****************************Division -2- Section -3- ********************************** -->
    <div class="bout" dir="rtl"> <a href="http://www.maaloma.net/dvisite.php" rel="nofollow noopener noreferrer" target="_blank">آخر المواضيع قراءة:</a></div>

    </div>

    <div id="Div1Section3"> <!-- *****************************Division -1- Section -3- ********************************** -->
    <div class="bout"> <a href="http://www.maaloma.net/religieux/" rel="nofollow noopener noreferrer" target="_blank">دين و دنيا</a></div>

    </div>
    <div id="Div3Section3"> <!-- *****************************Division -2- Section -3- ********************************** -->

    <div class="bout"><a href="http://www.maaloma.net/health/" rel="nofollow noopener noreferrer" target="_blank">صحة و جمال</a></div>

    </div>
    <div id="Div4Section3"> <!-- *****************************Division -1- Section -3- ********************************** -->
    <div class="bout"> <a href="http://www.maaloma.net/technologie/" rel="nofollow noopener noreferrer" target="_blank">علوم و تكنولوجيا</a></div>

    // Connexion à la base de données
    try
    {
    $pdo_options[PDO::ATTR_ERRMODE] = PDO::ERRMODE_EXCEPTION;
    $bdd = new PDO('mysql:host=localhost;dbname=maaloman_maaloma', 'maaloman_jamal', '27081988',array (PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES \'UTF8\''));

    // On ajoute une entrée dans la table jeux_video
    //$bdd->exec('UPDATE articles SET nb= nb+1 ');
    $reponse = $bdd->query('SELECT sotitre,titre,image,id, contenu FROM articles where cat="tech" ORDER BY id DESC LIMIT 0,4 ');
    // Affichage de chaque message (toutes les données sont protégées par htmlspecialchars)
    while ($donnees = $reponse->fetch())
    {
    echo '<div id="oujdid" dir="rtl"> <p><a href="http://www.maaloma.net/articles.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="titacc">
    <img id="flotte" src="http://www.maaloma.net/images/' . htmlspecialchars($donnees['image']) . '">
    <strong>' . htmlspecialchars($donnees['titre']) . '</strong></a><br/>
    <strong dir="rtl" class="contenu" > ' . htmlspecialchars($donnees['sotitre']) . '</strong><a href="http://www.maaloma.net/articles.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="tex" title="التفاصيل"> [...]</a></p></div>';}
    }catch(Exception $e)
    {
    die('Erreur : '.$e->getMessage());
    }
    ?>
    </div>
    <div id="Div4Section3"> <!-- *****************************Division -2- Section -3- ********************************** -->
    <div class="bout"> <a href="http://www.maaloma.net/homme_femme/" rel="nofollow noopener noreferrer" target="_blank">الرجل و المرأة</a></div>

    </div>
    <?php include("slideslide.php"); ?>
    <div id="Div4Section3"> <!-- *****************************Division -1- Section -3- ********************************** -->
    <div class="bout"> <a href="http://www.maaloma.net/astuces/index.php?page=1" rel="nofollow noopener noreferrer" target="_blank">خدع الحاسوب</a></div>

    // Connexion à la base de données
    try
    {
    $pdo_options[PDO::ATTR_ERRMODE] = PDO::ERRMODE_EXCEPTION;
    $bdd = new PDO('mysql:host=localhost;dbname=maaloman_maaloma', 'maaloman_jamal', '27081988',array (PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES \'UTF8\''));

    // On ajoute une entrée dans la table jeux_video
    //$bdd->exec('UPDATE articles SET nb= nb+1 ');
    $reponse = $bdd->query('SELECT sotitre,titre,image,id, contenu FROM astuces ORDER BY id DESC LIMIT 0,4');
    // Affichage de chaque message (toutes les données sont protégées par htmlspecialchars)
    while ($donnees = $reponse->fetch())
    {
    echo '<div id="oujdid" dir="rtl"> <p><a href="http://www.maaloma.net/astuces.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="titacc">
    <img id="flotte" src="http://www.maaloma.net/images/' . htmlspecialchars($donnees['image']) . '">
    <strong>' . htmlspecialchars($donnees['titre']) . '</strong></a><br/>
    <strong dir="rtl" class="contenu" > ' . htmlspecialchars($donnees['sotitre']) . '</strong><a href="http://www.maaloma.net/articles.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="tex" title="التفاصيل"> [...]</a></p></div>';}
    }catch(Exception $e)
    {
    die('Erreur : '.$e->getMessage());
    }
    ?>
    </div>
    <div id="Div4Section3"> <!-- *****************************Division -1- Section -3- ********************************** -->
    <div class="bout"> <a href="http://www.maaloma.net/histoires/" rel="nofollow noopener noreferrer" target="_blank">قصص</a></div>

    // Connexion à la base de données
    try
    {
    $pdo_options[PDO::ATTR_ERRMODE] = PDO::ERRMODE_EXCEPTION;
    $bdd = new PDO('mysql:host=localhost;dbname=maaloman_maaloma', 'maaloman_jamal', '27081988',array (PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES \'UTF8\''));

    // On ajoute une entrée dans la table jeux_video
    //$bdd->exec('UPDATE articles SET nb= nb+1 ');
    $reponse = $bdd->query('SELECT sotitre,titre,image,id, contenu FROM articles where cat="hst" ORDER BY id DESC LIMIT 0,4 ');
    // Affichage de chaque message (toutes les données sont protégées par htmlspecialchars)
    while ($donnees = $reponse->fetch())
    {
    echo '<div id="oujdid" dir="rtl"> <p><a href="http://www.maaloma.net/articles.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="titacc">
    <img id="flotte" src="http://www.maaloma.net/images/' . htmlspecialchars($donnees['image']) . '">
    <strong>' . htmlspecialchars($donnees['titre']) . '</strong></a><br/>
    <strong dir="rtl" class="contenu" > ' . htmlspecialchars($donnees['sotitre']) . '</strong><a href="http://www.maaloma.net/articles.php?num='. htmlspecialchars($donnees['id']) .'" rel="nofollow noopener noreferrer" target="_blank" id="tex" title="التفاصيل"> [...]</a></p></div>';}
    }catch(Exception $e)
    {
    die('Erreur : '.$e->getMessage());
    }
    ?>
    </div>
    </section>
    <footer>
    <div id="pied_page">
    <?php include("pied_page.php"); ?>
    </div>
    </footer>
    </div>

    </body>
    </html>
    0