Paul

Utilisateur open source
  • Compteur de contenus

    29
  • Inscrit(e) le

  • Dernière visite


Réputation sur la communauté

0 Neutral

À propos de Paul

  • Rang
    Membre

Activité de Paul

  1. Paul a ajouté un sujet dans Module PEEL Premium pour PEEL SHOPPING   

    Ouverture du ticket ....
    J'ai dans ma boite email ce genre de message tous les jours :



    ou encore :




    avec comme titre et objet: Ouverture du ticket 698 , 700 etc...
    savez vous d'où cela peux provenir car c'est vraiment trés chiant.


    l'email change mais semble tj provenir de yahoo: ( ex: ogzmough@yahoo.com)
    • 2 réponses
    • 2 393 vues
  2. Paul a ajouté un message dans un sujet  Notice: Undefined   

    sujet Fermé, j'ai trouvé la solution

    merci paulanna
    • 0
  3. Paul a ajouté un message dans un sujet  Notice: Undefined   

    c'est bon je n'ai plus ces 4erreurs (jai remplacé le fichiers fonctions) mais par contre j'ai lors de la commande qq d'étrange: lors de la 3eme étape de la commande:



    alors que le fichier request est bien sur mon disque dur.
    j'ai alors modifié (pensant que cela pouver avoir une raison) comme cité dans le forum : http://forum.peel.fr/index.php?showtopic=863 , étant chez OVH

    mais rien n'y fait.
    • 0
  4. Paul a ajouté un sujet dans Module PEEL Premium pour PEEL SHOPPING   

    Notice: Undefined
    bonjour, j'ai qq erreur lorsque mon client commande par carte bancire ( bouton radio , dans formulaire de commande) :

    Notice: Undefined index: pays2 in /home.13/s/o/s/sosmusic/www/shop/lib/fonctions/fonctions.php on line 390

    Notice: Undefined index: transport in /home.13/s/o/s/sosmusic/www/shop/lib/fonctions/fonctions.php on line 393

    Notice: Undefined index: cgv in /home.13/s/o/s/sosmusic/www/shop/lib/fonctions/fonctions.php on line 394

    Notice: Undefined index: tarif_paiement in /home.13/s/o/s/sosmusic/www/shop/achat/achat_maintenant.php on line 73


    Peel version 2.9.3, pouvez vous m'aider?
    • 4 réponses
    • 2 640 vues
  5. Paul a ajouté un message dans un sujet  prob catégories   

    problème résolu , merci encore willy
    • 0
  6. Paul a ajouté un message dans un sujet  prob catégories   

    <? include("../configuration.inc.php"); necessite_identification(); necessite_priv("admin"); $DOC_TITLE = "G&eacute;rer les produits"; include("modeles/haut.php"); $start = vn($_REQUEST['start']);// D&eacute;termine la variable start (d&eacute;but de page) switch (vb script:return confirm('&ecirc;tes-vous s&ucirc;r de vouloir supprimer le produit <?=$ligne['nom_'.$_SESSION['langue'].''] ?> ?');" class=normal title="Supprimer <?=$ligne['nom_'.$_SESSION['langue'].''] ?>" href="<?=$_SERVER['PHP_SELF']?>?mode=suppr&id=<?=$ligne['id'] ?>"> <img src="<?=$wwwroot?>/administrer/images/b_drop.png" border="0"></a> </td> <td class=normal align="center"><?echo $ligne['reference'] ?></td> <td class=normal align="center"> <?php $sqlCAT = "SELECT id, nom_".$_SESSION['langue']." FROM peel_categories c, peel_produits_categories pc WHERE pc.produit_id = ".$ligne['id']." AND c.id = pc.categorie_id"; $resCAT = mysql_query($sqlCAT); if (mysql_num_rows($resCAT) > 0) { while ($cat = mysql_fetch_array($resCAT)) { echo html_entity_decode($cat['nom_'.$_SESSION['langue'].''])."<br />"; } } else { echo "<font color=\"red\"><b>n.c</b></font>"; } ?> </td> <td class=normal align="center"><a class=normal title="Modifier ce produit" href="<?=$_SERVER['PHP_SELF']?>?mode=modif&id=<?=$ligne['id'] ?>"><?=html_entity_decode($ligne['nom_'.$_SESSION['langue'].''])?></a></td> <td class=normal align="center"><?=fprix($ligne['prix']) ?> &euro; T.T.C</td> <td align=center class=normal><?if (empty($ligne['etat'])) {echo "<img src=".$wwwroot."/administrer/images/puce-blanche.gif>";} else {echo "<img src=".$wwwroot."/administrer/images/puce-verte.gif>";} ?></td> <td class=normal align="center"> <?php if ($ligne['on_stock'] == 1) {?> <a class=petit title="G&eacute;rer les stocks" href="<?=$_SERVER['PHP_SELF']?>?mode=stock&id=<?=$ligne['id'] ?>"> <img src=<?=$wwwroot?>/administrer/images/stock.gif border=0></a> <?php $sqlEtatStock = "SELECT image FROM peel_etatstock WHERE id = '".$ligne['etat_stock']."'"; $resEtatStock = mysql_query($sqlEtatStock); $EtatStock = mysql_fetch_object($resEtatStock); if (!empty($EtatStock->image)) { echo "<img src=\"".$repertoire_images."".$EtatStock->image."\" />"; } } else { echo "n.a"; }?></td> <td class=normal align="center"><?=$ligne['points'] ?> pts</td> <td class=normal align="center"><?=return_date_fr($ligne['date_maj']) ?></td> </tr> <tr><td align="center" class="normal" colspan="10"> <? $i++; } } //Boutons pr&eacute;c&eacute;dent et suivant $Links-> pMultipage(); echo "</td></tr></table>"; } function affiche_liste_produits_stocknul($start, $frm) { global $wwwroot; global $categorie_options; ?> <table border="0" class="tablespace" width="760"> <tr> <td class="entete" colspan="2">Liste des produits dont le stock est nul</td> </tr> <? $Links = new MultiPage(); $Links-> ResultPerPage = 90; $Links-> LinkPerPage = 4; $Links-> Template = "tpl1.htm"; $Links-> SqlRequest = "SELECT p.id, p.nom_".$_SESSION['langue'].", s.stock FROM `peel_stocks` s, peel_produits p WHERE s.stock <= 0 AND p.id = s.produit_id ORDER BY p.id"; $Links-> Initialize(); $resHS=mysql_query($Links-> LimitSQL); if (mysql_num_rows($resHS) == 0) { echo "<tr><td class=normal><b>Tous les produits sont en stock</b></td></tr>"; } else { ?> <? $i = 0; echo "<table border=\"0\" class=\"tablespace\" width=\"760\">"; echo "<tr><td class=\"menu\">Action</td><td class=\"menu\">Produit</td></tr>"; while ($HS = mysql_fetch_array($resHS)) { echo "<tr ><td class=normal align=\"center\"><a href=$wwwroot/administrer/produits.php?mode=stock&id=".$HS['id']."><img src=\"$wwwroot/administrer/images/stock.gif\" border=\"0\"></a></td><td class=normal><a href=$wwwroot/administrer/produits.php?mode=modif&id=".$HS['id'].">".html_entity_decode($HS['nom_'.$_SESSION['langue'].''])."</a></td></tr>"; } } ?> <tr><td align="center" class="normal" colspan="4"> <? //Boutons pr&eacute;c&eacute;dent et suivant $Links-> pMultipage(); echo "</td></tr></table>"; } function affiche_liste_produits_acommander() { global $wwwroot; global $categorie_options; ?> <table border="0" class="tablespace" width="760"> <tr> <td class="normal" colspan="2"> <form method="POST" action="<?=$_SERVER['PHP_SELF']?>?start=0&mode=recherche"> <table border="0" cellpadding="0" cellspacing="2" width="100%"> <tr><td colspan="2" class="entete">Choisir vos crit&egrave;res de recherche</td></tr> <tr> <td class="normal">Etat du produit : <br /> <select size="1" name="etat" class="formulaire1"> <option value="NULL">Tous les produits</option> <option value="1">Produits en ligne</option> <option value="0">Produits en attente</option> </select> </td> <td class="normal">Cat&eacute;gories<br /> <select size="1" name="categorie" class="formulaire1"> <option value="NULL">Toutes les cat&eacute;gories</option> <?php if (!isset($categorie_id)) { $categorie_id = 0; } $frm['categories'] = array($categorie_id); //echo $frm['categories']; construit_arbo_cat($categorie_options,$frm['categories']); echo $categorie_options; ?> </select> </td> </tr> <tr> <td class="normal" valign="top"> R&eacute;f&eacute;rence du produit : <input type="text" name="reference" size="15" class="formulaire1" value=""> </td> </tr> <tr> <td class="normal" valign="top">Le produit est-il en page d'accueil ?<br /> <span class="normal"> <input type="radio" name="homepage" value="NULL" checked>peu importe <input type="radio" name="homepage" value="1" >oui <input type="radio" name="homepage" value="0" >non </span> </td> </tr> <tr><td colspan="2" height="5" class="label"><img src="<?=$wwwroot?>/images/blank.gif" height="5"></td></tr> <tr> <td align="center" colspan="2"><input class="bouton" type="submit" value="Rechercher" class="formulaire1" name="action"> </td> </tr> </table> </form> </td></tr> <tr> <td class="entete" colspan="2">Liste des produits &agrave; commander</td> </tr> <? $Links = new MultiPage(); $Links-> ResultPerPage = 50; $Links-> LinkPerPage = 4; $Links-> Template = "tpl1.htm"; $Links-> SqlRequest = "SELECT p.id, p.reference, oi.nom_produit as nom, oi.promotion, oi.prix, oi.couleur, oi.taille, oi.delivery_stock, oi.commande_id, oi.order_stock FROM peel_commandes_articles oi LEFT JOIN peel_produits p ON (oi.produit_id = p.id) WHERE order_stock > 0"; $Links-> Initialize(); $resHS=mysql_query($Links-> LimitSQL); if (mysql_num_rows($resHS) == 0) { echo "<tr><td class=normal><b>Aucun produit &agrave; commander</b></td></tr>"; } else { ?> <? $i = 0; echo "<table border=\"0\" class=\"tablespace\" width=\"760\">"; echo "<tr><td class=\"menu\">Action</td><td class=\"menu\">Produit</td><td class=\"menu\" align=\"center\">Prix de vente</td><td class=\"menu\" align=\"center\">A commander</td><td class=\"menu\" align=\"center\">D&eacute;tail de la commande</td></tr>"; while ($HS = mysql_fetch_array($resHS)) { echo "<tr ><td class=normal align=\"center\"> <a href=$wwwroot/administrer/produits.php?mode=stock&id=".$HS['id']."><img src=\"$wwwroot/administrer/images/stock.gif\" border=\"0\"></a></td> <td class=normal><a href=$wwwroot/administrer/produits.php?mode=modif&id=".$HS['id'].">".html_entity_decode($HS['nom'])."</a><br />Couleur : ".vb($HS['couleur'])."<br />Taille : ".vb($HS['taille'])."<br />Appro pr&eacute;vue : ".vb($HS['delivery_stock'])."</td> <td class=\"normal\" align=\"center\">".$HS['prix']." &euro; TTC</td> <td class=\"label\" align=\"center\">".$HS['order_stock']."</td> <td class=\"normal\" align=\"center\"><a href=\"commandes.php?mode=details&id=".$HS['commande_id']."\">commande ".$HS['commande_id']."</a></td> </tr>"; } } ?> <tr><td align="center" class="normal" colspan="5"> <? //Boutons pr&eacute;c&eacute;dent et suivant $Links-> pMultipage(); echo "</td></tr></table>"; } function valide_form_produit(&$frm, &$erreurs) { $erreurs = array(); $msg = array(); if (empty($frm['nom_fr'])) { $erreurs['nom_fr'] = true; $msg['nom_fr'] = " Vous devez ins&eacute;rer un nom de produit."; } return $msg; } function affiche_formulaire_stockall() { /* Affiche le formulaire de modification pour le produit sélectionné */ global $wwwroot; $resProd = mysql_query("SELECT id, nom FROM peel_produits WHERE etat = '1'") or DIE('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR()); ?> <form name="entryform" method="post" action="<?=$_SERVER['PHP_SELF']?>?start=0"> <input type="hidden" name="mode" value="InsereStockAll"> <table border="1" cellpadding=0 cellspacing=1 width=100%> <tr><td height="1" bgcolor="#336699" colspan="4"><img src="<?=$wwwroot?>/images/blank.gif" height="1"></td></tr> <tr bgcolor="#EEEEEE" colspan="4"> <td class="titre" colspan="4">Ajouter les stocks</td> </tr> <tr><td height="1" bgcolor="#336699" colspan="4"><img src="<?=$wwwroot?>/images/blank.gif" height="1"></td></tr> <tr><td class="label" align="center">Produit</td><td class="label" align="center">Stock</td><td class="label" align="center">Couleur</td><td class="label" align="center">Taille</td></tr> <? if (mysql_num_rows($resProd)>0) { while ($prod = mysql_fetch_array($resProd)) { $resStock = mysql_query("SELECT * FROM peel_stocks WHERE produit_id = '".$prod['id']."'"); while ($Stock = mysql_fetch_array($resStock)) { ?> <tr> <td align="center" class="normal"> <input type="hidden" name="id[]" value="<?echo $prod['id']?>"><?echo html_entity_decode($prod['nom'])?> </td> <td align="center"> <input type="text" class="formulaire1" style="width:50px" name="stock[]" value="<?echo $Stock['stock']?>"> </td> <td class="normal" align="center"> <input type="hidden" name="couleur[]" value="<?echo $Stock['couleur_id']?>"> <?php $Couleur = mysql_fetch_array(mysql_query("SELECT nom FROM peel_couleurs WHERE id = '".$Stock['couleur_id']."'")); echo html_entity_decode($Couleur['nom']); ?> </td> <td class="normal" align="center"> <input type="hidden" name="taille[]" value="<?echo $Stock['taille_id']?>"> <?php $Taille = mysql_fetch_array(mysql_query("SELECT nom FROM peel_tailles WHERE id = '".$Stock['taille_id']."'")); echo html_entity_decode($Taille['nom']); ?> </td> </tr> <? } } } ?> <tr><td colspan="4" align="center"><input type="submit" value="METTRE A JOUR LES STOCKS" class="bouton"></td></tr> </table></form> <? } function update_stockall_produit($frm) { /* Ajoute un nouveau sous-produit sous le parent $id. Les champs sont dans la variable $frm */ mysql_query("DELETE FROM peel_stocks"); for ($i = 0; $i < count($frm["stock"]); $i++) { mysql_query(" INSERT INTO peel_stocks ( produit_id ,taille_id ,couleur_id ,stock ) VALUES ( '{$frm["id"][$i]}' ,'{$frm["taille"][$i]}' ,'{$frm["couleur"][$i]}' , '{$frm["stock"][$i]}') "); } } ?>
    • 0
  7. Paul a ajouté un message dans un sujet  prob catégories   

    je vous met le code des pages template et fonctions ):


    <?php


    /**********************************/

    /* FONCTIONS DE LA PAGE D ACCUEIL */

    /**********************************/



    function print_on_specials() {



    /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */

    global $wwwroot, $repertoire_modele, $repertoire_images, $shirt;



    $sql = "SELECT p.id FROM peel_produits p WHERE p.on_special = '1' AND p.etat = '1'";



    $qid = mysql_query($sql) or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());



    if (mysql_num_rows($qid) > 0) {



    $nb_cellules = mysql_num_rows($qid);



    $nb_colonnes = 2;



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td colspan=".$nb_colonnes." class=\"entete\"><img src=\"images/fleche.gif\" />&nbsp;".SELECTION."</td></tr>";



    $j = 0;



    while ($prod = mysql_fetch_array($qid))

    {



    if ( $j % $nb_colonnes == 0 ) { echo "<tr valign=top>"; }



    if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) {



    // on affiche une cellule

    if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) { echo "<td class=\"newsCelluleOne\" width=\"50%\">"; } else { echo "<td class=\"newsCelluleTwo\" width=\"50%\">"; }



    template_index_produit($prod['id'],$where = "AND p.on_special = '1'");



    }

    echo "</td>";



    $j++;



    if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) {

    echo "</tr>";

    }



    }



    echo "</table>";



    }



    }





    function print_sell_flash() {



    /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */

    global $wwwroot, $repertoire_modele, $repertoire_images;



    $sql = "SELECT p.id, p.nom_".$_SESSION['langue'].", p.promotion, p.descriptif_".$_SESSION['langue'].", p.image1, p.image2, p.prix, p.prix_revendeur, p.points, p.comments FROM peel_produits p

    WHERE p.on_flash = '1' AND p.etat = '1' AND now() < flash_end";



    $qid = mysql_query($sql)

    or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());



    if (mysql_num_rows($qid) > 0) {



    $nb_cellules = mysql_num_rows($qid);



    $nb_colonnes = 1;



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td colspan=".$nb_colonnes." class=\"entete\">".FLASH."</td></tr>";



    $j = 0;



    while ($prod = mysql_fetch_array($qid))

    {



    if ( $j % $nb_colonnes == 0 ) {echo "<tr valign=top>";}



    if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) {



    // on affiche une cellule

    echo "<td class=\"normal\">";



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td align=\"center\" valign=\"middle\">";



    if (!empty($prod['image1'])) {



    if (!empty($prod['image2'])) {



    echo "<a href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">";



    }



    echo "<img src=\"$wwwroot/administrer/upload/".$prod['image1']."\"/>";



    if (!empty($prod['image2'])) {



    echo "</a><br /><a class=\"petit\" href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">zoom</a>";



    }



    } else {



    echo "<img src=\"$wwwroot/images/photo-non-disponible.gif\">";



    }



    echo "</td>";



    echo "<td><img src=\"images/blank.gif\" border=\"0\" width=\"5\" height=\"1\"></td>";



    echo "<td class=\"normal\">";



    echo "<a class=\"titre\" href=\"achat/produit_details.php?id=".$prod['id']."\">".stripslashes($prod['nom_'.$_SESSION['langue'].''])."</a>";



    echo "</td></tr>";



    echo "<tr>";



    echo "<td class=\"normal\" colspan=\"3\">";



    echo "<div class=\"texte\">".nl2br(stripslashes($prod['descriptif_'.$_SESSION['langue'].'']))."</div>";



    # AFFICHAGE DES POINTS

    if (!empty($prod['points'])) {echo POINT." : ".$prod['points']." <br />";}



    echo "</td></tr>";



    echo "<tr><td class=\"normal\" colspan=\"3\">";



    # FONCTION GERANT L'AFFICHAGE DU STOCK DES PRIX ET DES CRITERES COULEUR / TAILLE



    echo print_critere_stock_prix($prod['id']);



    echo "</td></tr></table>";



    }



    echo "</td>";



    $j++;



    if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) {

    echo "</tr>";

    }



    }



    echo "</table>";



    }



    }



    function print_categorie() {

    /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */

    global $wwwroot, $repertoire_modele;



    $qid = mysql_query("SELECT id, nom_".$_SESSION['langue'].", image FROM peel_categories WHERE etat = '1' AND on_special = '1'") or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());



    if (mysql_num_rows($qid) > 0) {



    $nb_cellules = mysql_num_rows($qid);

    $nb_colonnes = 2;



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td colspan=".$nb_colonnes." class=\"entete\">".CATALOG."</td></tr>";



    $j = 0;



    while ($cat = mysql_fetch_array($qid))

    {

    if ( $j % $nb_colonnes == 0 ) {

    echo "<tr valign=top>";

    }

    if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) {

    // on affiche une cellule

    echo "<td class=petit width=50%>";



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td align=\"center\"><a class=\"label\" href=\"achat/index.php?catid=".$cat['id'].">".stripslashes($cat['nom_'.$_SESSION['langue'].''])."</a></td></tr>";



    echo "<tr><td align=\"center\" valign=\"middle\">";



    if (!empty($cat['image'])) {



    echo "<div align=\"center\"><img src=\"administrer/upload/".$cat['image']."\" title=\"".stripslashes($cat['nom_'.$_SESSION['langue'].''])."\" /></div>";



    } else {



    echo "<div align=center><img src=\"$wwwroot/images/photo-non-disponible.gif\"></div>";



    }



    echo "</td></tr>";



    echo "</td></tr></table>";





    }



    echo "</td>";



    $j++;



    if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) {



    echo "</tr>";



    }



    }



    echo "</table>";





    }

    }



    function print_actu() {



    global $wwwroot;



    $sql_ACTU = "SELECT p.id, p.surtitre_".$_SESSION['langue'].", p.titre_".$_SESSION['langue'].", p.chapo_".$_SESSION['langue'].", p.texte_".$_SESSION['langue']."

    , p.image1, p.on_special, p.date_maj, pc.rubrique_id

    FROM peel_articles p, peel_articles_rubriques pc WHERE p.id = pc.article_id AND p.on_special = '1' AND p.etat = '1' ORDER BY p.date_maj DESC LIMIT 0,1";



    $query_ACTU = mysql_query($sql_ACTU) or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());



    if (mysql_num_rows($query_ACTU) > 0) {



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    while ($art = mysql_fetch_array($query_ACTU)) {



    echo "<tr>";



    echo "<td class=\"normal\">";



    echo "<span class=\"petit\">".date("d-m-Y")."</span><br />";



    echo "<span class=\"titre\">".stripslashes($art['titre_'.$_SESSION['langue'].''])."</span>";



    if (!empty($art['image1'])) {



    echo "<img src=\"$wwwroot/administrer/upload/".$art['image1']."\" align=\"left\">";



    }



    echo "<span class=\"normal\"><br /><br />".nl2br(stripslashes($art['chapo_'.$_SESSION['langue'].'']))."</span>";



    echo "</td></tr>";



    }



    echo "</table>";



    }



    }





    function print_top() {

    /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */

    global $wwwroot;



    $qid = mysql_query("SELECT p.id, p.nom_".$_SESSION['langue'].", p.image1, p.prix, p.promotion FROM peel_produits p WHERE p.on_top = '1' AND p.etat = '1' LIMIT 0,5");



    if (mysql_num_rows($qid) > 0) {



    echo "<div style=\"border: 1px solid #eee;padding:1px;text-align:center;\" class=\"label\">".TOP."</div>";



    while ($prod = mysql_fetch_array($qid)) {

    ?>

    <?

    }

    }

    }



    function print_new() {



    /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */



    global $wwwroot;



    $qid = mysql_query("SELECT p.id, p.nom_".$_SESSION['langue'].", p.image1 FROM peel_produits p WHERE p.on_new = '1' AND p.etat = '1' LIMIT 0,5") or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());



    if (mysql_num_rows($qid) > 0) {



    echo "<div style=\"border: 1px solid #eee;padding:1px;text-align:center;\" class=\"label\">".NEWS."</div>";



    while ($prod = mysql_fetch_array($qid)) {

    ?><style type="text/css">

    <!--

    body,td,th {

    color: #000000;

    }

    -->

    </style>

    <div style="background:#0879AA;border: 0px solid #F4F4EA;padding:6px;text-align:center;">

    <b><a href="achat/produit_details.php?id=<? echo $prod["id"] ?>" class="top"><? echo stripslashes($prod['nom_'.$_SESSION['langue'].''])?></a></b>

    <br />



    <? if (!empty($prod["image1"])) {?>



    <img src="<?=$wwwroot?>/administrer/upload/<?=$prod["image1"]?>" align="center" width="75" style="margin-right:10px " border="1">



    <?}?>

    <br />

    <a href="achat/produit_details.php?id=<? echo $prod["id"] ?>" class="top"><?echo MORE ?></a>

    </div>

    <br />

    <?

    }

    ?>

    </div>

    <?php

    }

    }



    function template_index_produit($id, $where) {



    global $wwwroot;

    global $repertoire_images;



    $sqlProd = "

    SELECT p.id

    , p.nom_".$_SESSION['langue']."

    , p.promotion

    , p.descriptif_".$_SESSION['langue']."

    , p.image1

    , p.image2

    , p.prix

    , p.prix_revendeur

    , p.points

    , p.comments

    FROM peel_produits p

    WHERE p.etat = '1' AND p.id = '".intval($id)."' ".$where."";



    $resProd = mysql_query($sqlProd);



    $prod = mysql_fetch_array($resProd);



    echo "<div align=\"center\" class=\"normal\">";



    echo "<p><a class=\"titre\" href=\"achat/produit_details.php?id=".$prod['id']."\">".html_entity_decode($prod['nom_'.$_SESSION['langue'].''])."</a></p>";



    if (!empty($prod['image1'])) {



    if (!empty($prod['image2'])) {



    echo "<a href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">";



    }



    echo "<img src=\"$wwwroot/administrer/upload/".$prod['image1']."\" width=\"100\" border=\"0\" title=\"".$prod['nom_'.$_SESSION['langue'].'']."\"/>";



    if (!empty($prod['image2'])) {



    echo "</a><br /><a class=\"petit\" href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">zoom</a>";



    }



    } else {



    echo "<img src=\"$wwwroot/images/photo-non-disponible.gif\">";



    }



    echo "<p>".html_entity_decode($prod['descriptif_'.$_SESSION['langue'].''])."</p>";



    print_critere_stock_prix($prod['id']);



    if (est_identifie()) {



    if (a_priv("admin")) {



    echo "<a href=\"administrer/produits.php?mode=modif&id=".$prod['id']."\" class=\"label\">MODIFIER LE PRODUIT</a>";



    }



    }



    echo "</div>";



    }





    // Fonction r&eacute;cursive pour rechercher si $noeud fait partie de l'arborescence d'un noeud donn&eacute;

    // Utilis&eacute; par construit_menu afin d'ouvrir les DIV necesssaires dans l'arborescence

    function parent_noeud_cat($noeud_cat,$aktul_cat,&$actif_cat){



    // Si c'est pas la racine

    if($aktul_cat != 0 && $noeud_cat != 0){

    // Recherche le parent du noeud &agrave; tester

    $sql=mysql_query("SELECT id, parent_id FROM peel_categories WHERE id = $aktul_cat");

    // r&eacute;cup&egrave;re le r&eacute;sultat

    $cat=mysql_fetch_array($sql);

    // Appel r&eacute;cursif jusqu'&agrave; la racine

    parent_noeud_cat($noeud_cat,$cat['parent_id'],$actif_cat);

    // Si le noeud test&eacute; est le noeud recherch&eacute;

    if($cat['parent_id']==$noeud_cat){

    // Met le drapeau &agrave; 1

    $actif_cat=1;

    }

    }

    }

    // Ca peut-&ecirc;tre simpa d'avoir une variable pour choisir avec ou sans arborescence ...

    // la fonction est appel&eacute; comme construit_menu (ne pas s'occuper de $indent)

    // Pour du HTML strict, il y a 2 erreurs qui sont la fermeture des balises <b>

    // On peut aller plus loin avec du javascript sur l'icone qui affiche / Cache le DIV sur l'&eacute;venements

    // OnMouseClic; ainsi on ne rechargerait pas la page &agrave; chaque fois.

    function construit_menu_arborescent_cat(&$sortie_cat, &$selectionne_cat, $parent_cat=0, $indent_cat=-1)

    {

    global $wwwroot, $catid;

    $indent_cat +=1;

    if(is_array($catid)) $catid=0;

    // Recherche de tous les noeuds ayant $parent comme noeud parent

    $qid = mysql_query("SELECT id, parent_id, nb, nom_".$_SESSION['langue']." FROM peel_categories WHERE parent_id = $parent_cat AND etat = '1' ORDER BY position");

    // Si la requete a abouti

    if($qid){

    // Pour toutes les entr&eacute;es

    while($cat = mysql_fetch_array($qid)){

    // Boucle pour ajouter l'indentation (une image vide)

    // Pour aller plus loin on peut g&eacute;rer des lignes de suite

    for($i=0;$i<$indent_cat;$i++){

    $sortie_cat .= "<img src='$wwwroot/images/mnu_empty.gif' border=0>";

    }

    // Recherche d'enfant pour d&eacute;terminer l'aspect de l'icone (feuille ou dossier)

    $fils_cat = mysql_query("SELECT id, parent_id, nom_".$_SESSION['langue']." FROM peel_categories WHERE parent_id = ".$cat['id']." AND etat = '1' ORDER BY position");

    $div_cat = mysql_num_rows($fils_cat);

    // Si il y a des enfants

    if ($div_cat) {

    // Ajout de l'icone du dossier

    $sortie_cat .= "<img src='$wwwroot/images/menplus.gif' border=0>&nbsp;";

    // Ajout du lien (identique &agrave; construit menu)

    $sortie_cat .= "<a class=menuleft href=$wwwroot/achat/index.php?catid=" . $cat['id'] .">";

    // Test si le noeud est le noeud actif (id), si oui, ajoute du gras (plus visuel)

    if($cat['id']==$catid) $sortie_cat .= "<b>";

    // Ajoute le nom de la cat&eacute;gorie et d&eacute;bute un calque DIV ayant pour ID l'Id de la cat&eacute;gorie

    $sortie_cat .= stripslashes($cat['nom_'.$_SESSION['langue'].'']);



    if (!empty($cat['nb'])) {$sortie_cat .= " (".$cat['nb'].") "; }



    $sortie_cat .= "</a></b><br /><DIV id=".$cat['id'];

    // Recherche si le noeud fait partie de l'arborescence du noeud actif

    parent_noeud_cat($cat['id'],$catid, $actif_cat=0);

    // Si Oui,

    if(($cat['id'] == $catid) || ($actif_cat == 1)){

    // Rends le calque visible

    $sortie_cat.= " style=\"display:yes\">\n";

    }

    else{

    // Sinon, rends le calque invisible METRE YES POUR AFFICHER LES SOUS CATS

    $sortie_cat.= " style=\"display:none\">\n";

    }

    }

    // Sinon, c'est un document

    else{

    // Ajoute l'image du document

    $sortie_cat .= "<img src='$wwwroot/images/menminus.gif' border=0>&nbsp;";

    // Ajoute le lien (identique &agrave; construit_menu)

    $sortie_cat .= "<a class=menuleft href=$wwwroot/achat/index.php?catid=" . $cat['id'] .">";

    // Si c'est la feuille active, la met en gras

    if($cat['id']==$catid) $sortie_cat .= "<b>";

    // Ajoute le nom

    $sortie_cat .= stripslashes($cat['nom_'.$_SESSION['langue'].'']);



    if (!empty($cat['nb'])) {$sortie_cat .= " (".$cat['nb'].") "; }



    $sortie_cat .= "</a></b><br />";

    }

    // Si c'est un noeud (cat&eacute;gorie)

    if($div_cat){

    // Appel r&eacute;cursif pour ajout des enfants

    construit_menu_arborescent_cat($sortie_cat, $selectionne_cat, $cat['id'], $indent_cat);

    // Ferme le calque

    $sortie_cat.="</div>";

    }

    }

    }

    }



    function print_rubrique() {

    /* Affiche la liste des catégories qui sont spéciales */

    global $wwwroot, $repertoire_modele;



    $qid = mysql_query("SELECT id, nom_".$_SESSION['langue'].", image FROM peel_rubriques WHERE etat = '1' AND on_special = '1'") or DIE('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR());

    if (mysql_num_rows($qid) > 0) {



    $nb_cellules = mysql_num_rows($qid);

    $nb_colonnes = 2;



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    $j = 0;



    while ($cat = mysql_fetch_array($qid))

    {

    if ( $j % $nb_colonnes == 0 ) {

    echo "<tr valign=top>";

    }

    if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) {

    // on affiche une cellule

    echo "<td class=petit width=50%>";



    echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";



    echo "<tr><td align=\"center\"><a class=\"label\" href=\"achat/index.php?catid=".$cat['id']."\">".stripslashes($cat['nom_'.$_SESSION['langue'].''])."</a></td></tr>";



    echo "<tr><td align=\"center\" valign=\"middle\">";



    if (!empty($cat['image'])) {



    echo "<div align=\"center\"><img src=\"administrer/upload/".$cat['image']."\" title=\"".stripslashes($cat['nom_'.$_SESSION['langue'].''])."\" /></div>";



    } else {



    echo "<div align=center><img src=\"$wwwroot/images/photo-non-disponible.gif\"></div>";



    }



    echo "</td></tr>";



    echo "</td></tr></table>";





    }



    echo "</td>";



    $j++;



    if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) {



    echo "</tr>";



    }



    }



    echo "</table>";





    }

    }



    function construit_menu_arborescent_rub(&$sortie_rub, &$selectionne_rub, $parent_rub=0, $indent_rub=-1)

    {

    global $wwwroot, $rubid, $repertoire_images;

    $indent_rub +=1;

    if(is_
    • 0
  8. Paul a ajouté un message dans un sujet  prob catégories   

    willy peut tu essayer de voir le code des pages qui fonctionnent mal, jcrois que c'est jsute les pages de l'admin.

    merki
    • 0
  9. Paul a ajouté un sujet dans Module PEEL Premium pour PEEL SHOPPING   

    prob catégories
    bonjour
    j'ai la version de peel 2.9.3


    Aprés avoir modifiées les marques de l'admin pour qu'elle apparaissent en ordre alphabétique que cela soit plus simple et afin de supprimer .
    dorénavant , lorsque je veux ajouter un nx produits, impossible de désigner une catégorie:



    avez vous un idée? merci d'avance
    • 11 réponses
    • 4 269 vues
  10. Paul a ajouté un sujet dans Module PEEL Premium pour PEEL SHOPPING   

    problemes Fatal error
    bonjour, j'ai qq ennuis avec peel premium en ce moment , toutes mes pages sont victimes de :

    "Fatal error: Cannot redeclare parent_noeud_cat() (previously declared in /home.13/s/o/s/sosmusic/www/shop/lib/fonctions/fonctions.php:268) in /home.13/s/o/s/sosmusic/www/shop/modeles/default/template.php on line 402"


    je ne sais comment résoudre cela , mais le plus incroyable c'est que je n'ai pas touché les fichiers fonctions et template.

    je vous marque les codes de chacun d'entres eux :

    Fonctions:


    <?php function est_identifie() { /* Retourne true si l'utilisateur des identifie */ return isset($_SESSION) && isset($_SESSION['utilisateur']) && !empty($_SESSION['utilisateur']['email']) && vb script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">"; } echo "<img src=\"$wwwroot/administrer/upload/".$prod['image1']."\"/>"; if (!empty($prod['image2'])) { echo "</a><br /><a class=\"petit\" href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">zoom</a>"; } } else { echo "<img src=\"$wwwroot/images/photo-non-disponible.gif\">"; } echo "</td>"; echo "<td><img src=\"images/blank.gif\" border=\"0\" width=\"5\" height=\"1\"></td>"; echo "<td class=\"normal\">"; echo "<a class=\"titre\" href=\"achat/produit_details.php?id=".$prod['id']."\">".stripslashes($prod['nom_'.$_SESSION['langue'].''])."</a>"; echo "</td></tr>"; echo "<tr>"; echo "<td class=\"normal\" colspan=\"3\">"; echo "<div class=\"texte\">".nl2br(stripslashes($prod['descriptif_'.$_SESSION['langue'].'']))."</div>"; # AFFICHAGE DES POINTS if (!empty($prod['points'])) {echo POINT." : ".$prod['points']." <br />";} echo "</td></tr>"; echo "<tr><td class=\"normal\" colspan=\"3\">"; # FONCTION GERANT L'AFFICHAGE DU STOCK DES PRIX ET DES CRITERES COULEUR / TAILLE echo print_critere_stock_prix($prod['id']); echo "</td></tr></table>"; } echo "</td>"; $j++; if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) { echo "</tr>"; } } echo "</table>"; } } function print_categorie() { /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */ global $wwwroot, $repertoire_modele; $qid = mysql_query("SELECT id, nom_".$_SESSION['langue'].", image FROM peel_categories WHERE etat = '1' AND on_special = '1'") or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR()); if (mysql_num_rows($qid) > 0) { $nb_cellules = mysql_num_rows($qid); $nb_colonnes = 2; echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">"; echo "<tr><td colspan=".$nb_colonnes." class=\"entete\">".CATALOG."</td></tr>"; $j = 0; while ($cat = mysql_fetch_array($qid)) { if ( $j % $nb_colonnes == 0 ) { echo "<tr valign=top>"; } if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) { // on affiche une cellule echo "<td class=petit width=50%>"; echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">"; echo "<tr><td align=\"center\"><a class=\"label\" href=\"achat/index.php?catid=".$cat['id'].">".stripslashes($cat['nom_'.$_SESSION['langue'].''])."</a></td></tr>"; echo "<tr><td align=\"center\" valign=\"middle\">"; if (!empty($cat['image'])) { echo "<div align=\"center\"><img src=\"administrer/upload/".$cat['image']."\" title=\"".stripslashes($cat['nom_'.$_SESSION['langue'].''])."\" /></div>"; } else { echo "<div align=center><img src=\"$wwwroot/images/photo-non-disponible.gif\"></div>"; } echo "</td></tr>"; echo "</td></tr></table>"; } echo "</td>"; $j++; if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) { echo "</tr>"; } } echo "</table>"; } } function print_actu() { global $wwwroot; $sql_ACTU = "SELECT p.id, p.surtitre_".$_SESSION['langue'].", p.titre_".$_SESSION['langue'].", p.chapo_".$_SESSION['langue'].", p.texte_".$_SESSION['langue']." , p.image1, p.on_special, p.date_maj, pc.rubrique_id FROM peel_articles p, peel_articles_rubriques pc WHERE p.id = pc.article_id AND p.on_special = '1' AND p.etat = '1' ORDER BY p.date_maj DESC LIMIT 0,1"; $query_ACTU = mysql_query($sql_ACTU) or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR()); if (mysql_num_rows($query_ACTU) > 0) { echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">"; while ($art = mysql_fetch_array($query_ACTU)) { echo "<tr>"; echo "<td class=\"normal\">"; echo "<span class=\"petit\">".date("d-m-Y")."</span><br />"; echo "<span class=\"titre\">".stripslashes($art['titre_'.$_SESSION['langue'].''])."</span>"; if (!empty($art['image1'])) { echo "<img src=\"$wwwroot/administrer/upload/".$art['image1']."\" align=\"left\">"; } echo "<span class=\"normal\"><br /><br />".nl2br(stripslashes($art['chapo_'.$_SESSION['langue'].'']))."</span>"; echo "</td></tr>"; } echo "</table>"; } } function print_top() { /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */ global $wwwroot; $qid = mysql_query("SELECT p.id, p.nom_".$_SESSION['langue'].", p.image1, p.prix, p.promotion FROM peel_produits p WHERE p.on_top = '1' AND p.etat = '1' LIMIT 0,5"); if (mysql_num_rows($qid) > 0) { echo "<div style=\"border: 1px solid #eee;padding:1px;text-align:center;\" class=\"label\">".TOP."</div>"; while ($prod = mysql_fetch_array($qid)) { ?> <? } } } function print_new() { /* Affiche la liste des cat&eacute;gories qui sont sp&eacute;ciales */ global $wwwroot; $qid = mysql_query("SELECT p.id, p.nom_".$_SESSION['langue'].", p.image1 FROM peel_produits p WHERE p.on_new = '1' AND p.etat = '1' LIMIT 0,5") or DIE('Une erreur de connexion &agrave; la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR()); if (mysql_num_rows($qid) > 0) { echo "<div style=\"border: 1px solid #eee;padding:1px;text-align:center;\" class=\"label\">".NEWS."</div>"; while ($prod = mysql_fetch_array($qid)) { ?><style type="text/css"> <!-- body,td,th { color: #000000; } --> </style> <div style="background:#0879AA;border: 0px solid #F4F4EA;padding:6px;text-align:center;"> <b><a href="achat/produit_details.php?id=<? echo $prod["id"] ?>" class="top"><? echo stripslashes($prod['nom_'.$_SESSION['langue'].''])?></a></b> <br /> <? if (!empty($prod["image1"])) {?> <img src="<?=$wwwroot?>/administrer/upload/<?=$prod["image1"]?>" align="center" width="75" style="margin-right:10px " border="1"> <?}?> <br /> <a href="achat/produit_details.php?id=<? echo $prod["id"] ?>" class="top"><?echo MORE ?></a> </div> <br /> <? } ?> </div> <?php } } function template_index_produit($id, $where) { global $wwwroot; global $repertoire_images; $sqlProd = " SELECT p.id , p.nom_".$_SESSION['langue']." , p.promotion , p.descriptif_".$_SESSION['langue']." , p.image1 , p.image2 , p.prix , p.prix_revendeur , p.points , p.comments FROM peel_produits p WHERE p.etat = '1' AND p.id = '".intval($id)."' ".$where.""; $resProd = mysql_query($sqlProd); $prod = mysql_fetch_array($resProd); echo "<div align=\"center\" class=\"normal\">"; echo "<p><a class=\"titre\" href=\"achat/produit_details.php?id=".$prod['id']."\">".html_entity_decode($prod['nom_'.$_SESSION['langue'].''])."</a></p>"; if (!empty($prod['image1'])) { if (!empty($prod['image2'])) { echo "<a href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">"; } echo "<img src=\"$wwwroot/administrer/upload/".$prod['image1']."\" width=\"100\" border=\"0\" title=\"".$prod['nom_'.$_SESSION['langue'].'']."\"/>"; if (!empty($prod['image2'])) { echo "</a><br /><a class=\"petit\" href=\"java script:OpenWin('".$repertoire_images."/".$prod['image2']."',300,300,'zoom')\">zoom</a>"; } } else { echo "<img src=\"$wwwroot/images/photo-non-disponible.gif\">"; } echo "<p>".html_entity_decode($prod['descriptif_'.$_SESSION['langue'].''])."</p>"; print_critere_stock_prix($prod['id']); if (est_identifie()) { if (a_priv("admin")) { echo "<a href=\"administrer/produits.php?mode=modif&id=".$prod['id']."\" class=\"label\">MODIFIER LE PRODUIT</a>"; } } echo "</div>"; } // Fonction r&eacute;cursive pour rechercher si $noeud fait partie de l'arborescence d'un noeud donn&eacute; // Utilis&eacute; par construit_menu afin d'ouvrir les DIV necesssaires dans l'arborescence function parent_noeud_cat($noeud_cat,$aktul_cat,&$actif_cat){ // Si c'est pas la racine if($aktul_cat != 0 && $noeud_cat != 0){ // Recherche le parent du noeud &agrave; tester $sql=mysql_query("SELECT id, parent_id FROM peel_categories WHERE id = $aktul_cat"); // r&eacute;cup&egrave;re le r&eacute;sultat $cat=mysql_fetch_array($sql); // Appel r&eacute;cursif jusqu'&agrave; la racine parent_noeud_cat($noeud_cat,$cat['parent_id'],$actif_cat); // Si le noeud test&eacute; est le noeud recherch&eacute; if($cat['parent_id']==$noeud_cat){ // Met le drapeau &agrave; 1 $actif_cat=1; } } } // Ca peut-&ecirc;tre simpa d'avoir une variable pour choisir avec ou sans arborescence ... // la fonction est appel&eacute; comme construit_menu (ne pas s'occuper de $indent) // Pour du HTML strict, il y a 2 erreurs qui sont la fermeture des balises <b> // On peut aller plus loin avec du javascript sur l'icone qui affiche / Cache le DIV sur l'&eacute;venements // OnMouseClic; ainsi on ne rechargerait pas la page &agrave; chaque fois. function construit_menu_arborescent_cat(&$sortie_cat, &$selectionne_cat, $parent_cat=0, $indent_cat=-1) { global $wwwroot, $catid; $indent_cat +=1; if(is_array($catid)) $catid=0; // Recherche de tous les noeuds ayant $parent comme noeud parent $qid = mysql_query("SELECT id, parent_id, nb, nom_".$_SESSION['langue']." FROM peel_categories WHERE parent_id = $parent_cat AND etat = '1' ORDER BY position"); // Si la requete a abouti if($qid){ // Pour toutes les entr&eacute;es while($cat = mysql_fetch_array($qid)){ // Boucle pour ajouter l'indentation (une image vide) // Pour aller plus loin on peut g&eacute;rer des lignes de suite for($i=0;$i<$indent_cat;$i++){ $sortie_cat .= "<img src='$wwwroot/images/mnu_empty.gif' border=0>"; } // Recherche d'enfant pour d&eacute;terminer l'aspect de l'icone (feuille ou dossier) $fils_cat = mysql_query("SELECT id, parent_id, nom_".$_SESSION['langue']." FROM peel_categories WHERE parent_id = ".$cat['id']." AND etat = '1' ORDER BY position"); $div_cat = mysql_num_rows($fils_cat); // Si il y a des enfants if ($div_cat) { // Ajout de l'icone du dossier $sortie_cat .= "<img src='$wwwroot/images/menplus.gif' border=0>&nbsp;"; // Ajout du lien (identique &agrave; construit menu) $sortie_cat .= "<a class=menuleft href=$wwwroot/achat/index.php?catid=" . $cat['id'] .">"; // Test si le noeud est le noeud actif (id), si oui, ajoute du gras (plus visuel) if($cat['id']==$catid) $sortie_cat .= "<b>"; // Ajoute le nom de la cat&eacute;gorie et d&eacute;bute un calque DIV ayant pour ID l'Id de la cat&eacute;gorie $sortie_cat .= stripslashes($cat['nom_'.$_SESSION['langue'].'']); if (!empty($cat['nb'])) {$sortie_cat .= " (".$cat['nb'].") "; } $sortie_cat .= "</a></b><br /><DIV id=".$cat['id']; // Recherche si le noeud fait partie de l'arborescence du noeud actif parent_noeud_cat($cat['id'],$catid, $actif_cat=0); // Si Oui, if(($cat['id'] == $catid) || ($actif_cat == 1)){ // Rends le calque visible $sortie_cat.= " style=\"display:yes\">\n"; } else{ // Sinon, rends le calque invisible METRE YES POUR AFFICHER LES SOUS CATS $sortie_cat.= " style=\"display:none\">\n"; } } // Sinon, c'est un document else{ // Ajoute l'image du document $sortie_cat .= "<img src='$wwwroot/images/menminus.gif' border=0>&nbsp;"; // Ajoute le lien (identique &agrave; construit_menu) $sortie_cat .= "<a class=menuleft href=$wwwroot/achat/index.php?catid=" . $cat['id'] .">"; // Si c'est la feuille active, la met en gras if($cat['id']==$catid) $sortie_cat .= "<b>"; // Ajoute le nom $sortie_cat .= stripslashes($cat['nom_'.$_SESSION['langue'].'']); if (!empty($cat['nb'])) {$sortie_cat .= " (".$cat['nb'].") "; } $sortie_cat .= "</a></b><br />"; } // Si c'est un noeud (cat&eacute;gorie) if($div_cat){ // Appel r&eacute;cursif pour ajout des enfants construit_menu_arborescent_cat($sortie_cat, $selectionne_cat, $cat['id'], $indent_cat); // Ferme le calque $sortie_cat.="</div>"; } } } } function print_rubrique() { /* Affiche la liste des catégories qui sont spéciales */ global $wwwroot, $repertoire_modele; $qid = mysql_query("SELECT id, nom_".$_SESSION['langue'].", image FROM peel_rubriques WHERE etat = '1' AND on_special = '1'") or DIE('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . MYSQL_ERROR()); if (mysql_num_rows($qid) > 0) { $nb_cellules = mysql_num_rows($qid); $nb_colonnes = 2; echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">"; $j = 0; while ($cat = mysql_fetch_array($qid)) { if ( $j % $nb_colonnes == 0 ) { echo "<tr valign=top>"; } if($j % $nb_colonnes !=0 OR $j % $nb_colonnes == 0 ) { // on affiche une cellule echo "<td class=petit width=50%>"; echo "<table align=\"center\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">"; echo "<tr><td align=\"center\"><a class=\"label\" href=\"achat/index.php?catid=".$cat['id']."\">".stripslashes($cat['nom_'.$_SESSION['langue'].''])."</a></td></tr>"; echo "<tr><td align=\"center\" valign=\"middle\">"; if (!empty($cat['image'])) { echo "<div align=\"center\"><img src=\"administrer/upload/".$cat['image']."\" title=\"".stripslashes($cat['nom_'.$_SESSION['langue'].''])."\" /></div>"; } else { echo "<div align=center><img src=\"$wwwroot/images/photo-non-disponible.gif\"></div>"; } echo "</td></tr>"; echo "</td></tr></table>"; } echo "</td>"; $j++; if ( $j % $nb_colonnes == 0 OR $j == $nb_cellules ) { echo "</tr>"; } } echo "</table>"; } } ?>
    • 1 réponse
    • 2 006 vues
  11. Paul a ajouté un message dans un sujet  problemes brand.php   

    même si je sais que c'est order by qui défini le sens, j'ai pas trouver la page pour les catégories, ( jai bien modifier qq order by dans la pages fonctions.php mais rien ni fait à jai remplacé pour chancun position par nom
    • 0
  12. Paul a ajouté un message dans un sujet  problemes brand.php   

    oui sa marche nickel , jessayerai de faire pareil pour les categories mais jsé pas ds quel fichier
    • 0
  13. Paul a ajouté un message dans un sujet  problemes brand.php   

    enfin sa marche, jte remerci bcp willy. dis moi tant qu'on y est tu n'aurai pas la méthode pour meter les marquesz de l'administrateur en ordre alphabétique "order by nom " mais joutrve pas où et aussi la liste des catégories en order by nom.


    merci d'avance
    • 0
  14. Paul a ajouté un message dans un sujet  problemes brand.php   

    j'ai remplacé le ORDER BY nom") par ORDER BY position") mais toujours rien, en plus d'avoir la liste par ordre aléatoire , cela n'a toujours aucun effet.

    Recherche par marque
    Il n'y pas de produit associé à cette marque ou vous n'avez sélectionné aucune marque. Choisissez une autre marque dans le menu.
    • 0
  15. Paul a ajouté un sujet dans Module PEEL Premium pour PEEL SHOPPING   

    rotation
    Bonjour, j'aimerai que sur mes pages nouveutés , il y ai une rotation de ces produits aléatoire, ex si la page doit afficher 10produits, que ces produits changent toutes les semaines par exmple .

    j'aurai voulu savoir si cela été possible, cordialement.
    • 1 réponse
    • 2 153 vues

Twitter Advisto ecommerce

Facebook PEEL Shopping