verod

Utilisateur open source
  • Compteur de contenus

    249
  • Inscrit(e) le

  • Dernière visite


Messages posté(e)s par verod


  1. :rolleyes: MOI QUI PENSAIS QUE CE PROBLEME AVAIT ETE RESOLU PAR L'EQUIPE PEEL !!!

    Ce soir, une cliente a passée une commande d'un article qui était affiché non disponible.

    C'est un article où il ne reste que une autre référence dans une autre taille.

    Si cette cliente avait sélectionner une autre taille, elle ne serait plus en stock et cela se serait affiché sur le bon de commande.

    Donc elle m'a pris une taille indisponible (j'ai fait le test ensuite et je confirme) et la commande a été validée tout de même...

    Ce bug n'était pas présent avant lorsque les icônes affichaient n'importe quoi...

    Alors merci Peel pour cette perte d'autant que mes produits n'ont pas de réassort ! Je me retrouve avec un problème d'icônes qui en fait n'influe en rien le stock et encore moins les commandes !


  2. Ouffff

    pb résolu, par mégarde j'ai tapé une touche avant de sauvegarder le fichier correctement.

    Plus de peur que de mal, j'ai donc supprimer le caractère de trop (c'est en faisant les touches de raccourci pour sauvegarder Alt+S pour "enregistrer sous" que un "s" est apparu. Je l'ai donc supprimé) et rechargé la page correctement sur le serveur...

    Que des frayeurs je me fais moi :D

    Merci Paulanna et désolée de t'avoir monopolisée un instant :P

    Vero

    J'édite: c'est pas fini ! arf :rolleyes:

    j'ai maintenant le message suivant si je lance le fichier du comparateur pour avoir le fichier txt:

    Une erreur de connexion à la base s est produite 119.

    Unknown column 'p.nom' in 'field list'

    Et ma bêtise est de ne pas avoir fais de backup de ce truc...

    Voici mon code du fichier mysql2comparateur.php

    <?
    
    
    include("../configuration.inc.php");
    
    
    
    
    necessite_identification();
    
    
    
    
    necessite_priv("admin");
    
    
    
    
    $DOC_TITLE = "[Export du catalogue produit]";
    
    
    
    
    include("../administrer/modeles/haut.php");
    
    
    
    
    echo "<table><tr><td class=\"entete\">Exportation TXT du catalogue $site vers les comparateurs de prix</td></tr></table>";
    
    
    
    
    switch(vb($_POST['mode'])) {
    
    
    
    
    case "lire" :
    
    
    
    
    if ($_POST['comparateur'] == "all") {
    
    
    
    
    db2txt($comparateur = "twenga");
    
    
    db2txt($comparateur = "kelkoo");
    
    
    db2txt($comparateur = "touslesprix");
    
    
    db2txt($comparateur = "shopping");
    
    
    db2txt($comparateur = "pangora");
    
    
    db2txt($comparateur = "leguide");
    
    
    db2txt($comparateur = "achetermoinscher");
    
    
    db2txt($comparateur = "pricerunner");
    
    
    db2txt($comparateur = "lesportif");
    
    
    
    
    } else {
    
    
    
    
    $comparateur = $_POST['comparateur'];
    
    
    
    
    db2txt($comparateur);
    
    
    
    
    }
    
    
    
    
    echo "<li type=\"square\"><b>Le fichier a &eacute;t&eacute; correctement export&eacute;.</b></li>";
    
    
    
    
    form2csv();
    
    
    
    
    break;
    
    
    
    
    default :
    
    
    form2csv();
    
    
    break;
    
    
    
    
    }
    
    
    
    
    include("../administrer/modeles/bas.php");
    
    
    
    
    /* FONCTIONS */
    
    
    
    
    function db2txt($comparateur)
    
    
    {
    
    
    global $wwwroot;
    
    
    
    
    $select = "select p.id, p.reference, p.nom, p.descriptif, p.description, p.poids, p.brand, p.image1, p.image2, p.prix, p.promotion, c.nom AS categorie, c.parent_id from peel_produits p, peel_categories c, peel_produits_categories pc WHERE p.lang = '".$_SESSION['langue']."' AND pc.produit_id = p.id AND c.id = pc.categorie_id ORDER BY id";
    
    
    
    
    $req = mysql_query($select) or die ('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . mysql_error());
    
    
    
    
    echo "<b>Nom du comparateur : $comparateur</b>";
    
    
    
    
    $csv_file = $comparateur."_".$_SESSION['langue']."_".date("Y").date("m").date("d").".".$_POST['format'];
    
    
    
    
    switch($comparateur) {
    
    
    
    
    	case "twenga";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    
    
    	fwrite($create_csv,"product_url|brand|description|price|merchant_id|in_stock|image_url|category\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?affilie=1852&id=".$prod['id'])."|");
    
    
    
    
    	   	fwrite($create_csv,$nom."|".$descriptif."|".$prix."|".$prod['id']."|0|");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image)."|".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "touslesprix";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"product url|name|description|regular price|offer_id|disponibilite|image url|merchant category\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?affilie=1859&id=".$prod['id'])."|");
    
    
    
    
    	   	fwrite($create_csv,$nom."|".$descriptif."|".$prix."|".$prod['id']."|0|");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image)."|".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "shopping";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"URL produit;Nom du produit;Description du produit;Prix du produit;Référence;URL image;Catégorie\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?id=".$prod['id']).";");
    
    
    
    
    	   	fwrite($create_csv,$nom.";".$descriptif.";".$prix.";".$id.";");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image).";".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    
    
    	case "pangora";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"offer-url|label|description|prices|offer-id|delivery-period|image-url|merchant-category\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?affilie=1851&id=".$prod['id'])."|");
    
    
    
    
    	   	fwrite($create_csv,$nom."|".$descriptif."|".$prix."|".$id."|3|");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image)."|".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "leguide";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"product url|name|description|regular price|offer_id|disponibilite|image url|merchant category\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?affilie=1785&id=".$id)."|");
    
    
    
    
    	   	fwrite($create_csv,$nom."|".$descriptif."|".$prix."|".$id."|0|");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image)."|".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "achetermoinscher";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"product url|name|description|regular price|offer_id|disponibilite|image url|merchant category\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?affilie=1865&id=".$id)."|");
    
    
    
    
    	   	fwrite($create_csv,$nom."|".$descriptif."|".$prix."|".$id."|0|");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image)."|".$categorie."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "pricerunner";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    	fwrite($create_csv,"Prix TTC;Fabricant;SKU du Fabricant;Identifiant unique;Code EAN;Nom du produit;Catégorie;URL du produit;Stock;Coût de livraison;URL de l'image produit;Description\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,"$prix €;$brand;;$id;;$nom;$categorie;");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?id=".$id).";");
    
    
    
    
    		fwrite($create_csv,"0;0.00;");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1'];} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image).";".$descriptif."\r\n");
    
    
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    
    
    
    
    	break;
    
    
    
    
    	case "kelkoo";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    
    
    	fwrite($create_csv,"#country=fr\r\n#type=basic\r\n#currency=EUR\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		$categorie = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,stripslashes("$wwwroot/achat/produit_details.php?id=".$id).";");
    
    
    
    
    	   	fwrite($create_csv,$nom.";".$descriptif.";".$prix.";".$id.";");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1']."";} else { $image = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image).";".stripslashes($categorie)."\r\n");
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    	break;
    
    
    
    
    	case "lesportif";
    
    
    
    
    	$csv_file = "export_lesportif.csv";
    
    
    
    
    	$create_csv = fopen($csv_file,"w");
    
    
    
    
    	fwrite($create_csv,"unique;libelle;optionvaleur1;resume;description;rayon;sousrayon;marque;prixt
    
    tc;tva;fraisdeport;poids;photo;photozoom\r\n");
    
    
    
    
    	while($prod = mysql_fetch_array($req))
    
    
    		{
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$fwrite = 0;
    
    
    
    
    		$optionvaleur1 = "";
    
    
    
    
    		$sqlStock = "SELECT stock, couleur_id, taille_id FROM peel_stocks WHERE produit_id = '".$id."' AND stock > 5";
    
    
    
    
    		$resStock = mysql_query($sqlStock) or die ('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . mysql_error());
    
    
    
    
    		while ($Stock = mysql_fetch_array($resStock)) {
    
    
    
    
    			$fwrite = 1;
    
    
    
    
    			if ($Stock['couleur_id'] != 0) { 
    
    
    
    
    				$resCouleur = mysql_query("SELECT nom FROM peel_couleurs WHERE id = '".$Stock['couleur_id']."'") or die ('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . mysql_error());
    
    
    
    
    				$Couleur = mysql_fetch_object($resCouleur);
    
    
    
    
    				$color = $Couleur->nom;
    
    
    
    
    			}
    
    
    
    
    			if ($Stock['taille_id'] != 0) { 
    
    
    
    
    				$resTaille = mysql_query("SELECT nom FROM peel_tailles WHERE id = '".$Stock['taille_id']."'") or die ('Une erreur de connexion à la base s est produite ' . __LINE__ . '.<p>' . mysql_error()); 
    
    
    
    
    				$Taille = mysql_fetch_object($resTaille);
    
    
    
    
    				$size = $Taille->nom;
    
    
    
    
    			}
    
    
    
    
    			if ($color != "" || $size != "") { 
    
    
    
    
    			$optionvaleur1 .= "$color - $size|";
    
    
    
    
    			}
    
    
    
    
    		}
    
    
    
    
    		$optionvaleur1 = ($optionvaleur1 != "") ? substr($optionvaleur1, 0, -1) : "";
    
    
    
    
    		if ($fwrite == 1) {
    
    
    
    
    		substr("abcdef", 0, -1);
    
    
    
    
    		$id = intval($prod['id']);
    
    
    
    
    		$nom = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['nom']))));
    
    
    
    
    		$descriptif = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['descriptif']))));
    
    
    
    
    		$description = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['description']))));
    
    
    
    
    
    
    		$brand = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['brand']))));
    
    
    
    
    		$reference = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['reference']))));
    
    
    
    
    		if ($prod['parent_id'] == 0) {
    
    
    
    
    			$rayon = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    			$ss_rayon = "";
    
    
    
    
    		} else {
    
    
    
    
    			$ss_rayon = TrimExt(strip_tags(html_entity_decode(stripslashes($prod['categorie']))));
    
    
    
    
    			$resCat = mysql_query("SELECT nom FROM peel_categories WHERE id = '".intval($prod['parent_id'])."'");
    
    
    
    
    			$Cat = mysql_fetch_object($resCat);
    
    
    
    
    			$rayon = TrimExt(strip_tags(html_entity_decode(stripslashes($Cat->nom))));
    
    
    
    
    		}
    
    
    
    
    		$tva= $prod['tva'];
    
    
    
    
    		$poids = $prod['poids'];
    
    
    
    
    		$prix = $prod['prix'] * (1-$prod["promotion"]/100);
    
    
    
    
    	   	fwrite($create_csv,"");
    
    
    
    
    		fwrite($create_csv,"$id;$nom;$optionvaleur1;$descriptif;$descriptif;$rayon;$ss_rayon;$brand;$prix;$tva;-1;$poids;");
    
    
    
    
    		if (!empty($prod['image1'])) {$image = "$wwwroot/upload/".$prod['image1']."";} else { $image = "";}
    
    
    
    
    		if (!empty($prod['image2'])) {$zoom = "$wwwroot/upload/".$prod['image2']."";} else { $zoom = "";}
    
    
    
    
    		fwrite($create_csv,htmlspecialchars($image).";".htmlspecialchars($zoom)."\r\n");
    
    
    
    
    		}
    
    
    
    
    	}
    
    
    
    
    	fclose($create_csv);
    
    
    
    
    	break;
    
    
    
    
    
    
    }
    
    
    mysql_free_result($req);
    
    
    
    
    echo "<br />Fichier export&eacute; : <a href=\"$wwwroot/comparateur/$csv_file\" target=\"_blank\">$wwwroot/comparateur/$csv_file</a>";
    
    
    
    
    echo "<br />Requête utilisée pour la génération du fichier csv : $select<br />";
    
    
    
    
    }
    
    
    
    
    function form2csv() {
    
    
    
    
    global $table;
    
    
    
    
    echo "<form method=\"POST\" name=\"prod2csv\" action=\"".$_SERVER['PHP_SELF']."\">";
    
    
    
    
    echo "<table cellspacing=\"5\" cellpadding=\"1\"><tr>";
    
    
    
    
    echo "<td><img src=\"images/pricerunner.gif\"   border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/pangora.gif\"  border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/leguide.gif\"  border=\"0\"></td>";
    
    
    
    
    echo "</tr><tr>";
    
    
    
    
    echo "<td><img src=\"images/kelkoo.gif\"  border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/e-comparateur.gif\"   border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/twenga.gif\"  border=\"0\"></td>";
    
    
    
    
    echo "</tr><tr>";
    
    
    
    
    echo "<td><img src=\"images/tlp.gif\"  border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/shopping.gif\"  border=\"0\"></td>";
    
    
    echo "<td><img src=\"images/amc.gif\"  border=\"0\"></td>";
    
    
    
    
    echo "</tr><tr>";
    
    
    
    
    echo "<td><img src=\"images/lesportif.gif\"  border=\"0\"></td>";
    
    
    echo "<td>&nbsp;</td>";
    
    
    echo "<td>&nbsp;</td>";
    
    
    
    
    echo "</tr></table>";
    
    
    
    
    echo "<div class=\"entete\">Exporter le catalogue de produits en choisissant le format et le comparateur : ";
    
    
    
    
    echo "<br \><br />Choisir le format d'exportation : ";
    
    
    
    
    echo "<select name=\"format\" class=\"formulaire1\">";
    
    
    
    
    echo "<option value=\"txt\">TXT</option>";
    
    
    /*
    
    
    echo "<option value=\"csv\">CSV</option>";
    
    
    echo "<option value=\"xml\">XML</option>";
    
    
    */
    
    
    echo "</select>";
    
    
    
    
    echo "<br \><br />Choisir le comparateur : ";
    
    
    echo "<select name=\"comparateur\" class=\"formulaire1\">";
    
    
    echo "<option value=\"all\">Tous les comparateurs</option>";
    
    
    echo "<option value=\"twenga\">Twenga</option>";
    
    
    echo "<option value=\"kelkoo\">Kelkoo</option>";
    
    
    echo "<option value=\"touslesprix\">Tous les prix</option>";
    
    
    echo "<option value=\"shopping\">Shopping</option>";
    
    
    echo "<option value=\"pangora\">Pangora</option>";
    
    
    echo "<option value=\"leguide\">Le guide - webmarchand</option>";
    
    
    echo "<option value=\"achetermoinscher\">Acheter moins cher</option>";
    
    
    echo "<option value=\"pricerunner\">Price Runner</option>";
    
    
    echo "<option value=\"lesportif\">Le Sportif</option>";
    
    
    echo "</select>";
    
    
    
    
    echo "<input type=\"hidden\" name=\"mode\" value=\"lire\">";
    
    
    
    
    echo "<input type=\"hidden\" name=\"table\" value=\"peel_produits\">";
    
    
    
    
    echo "<br \><br /><input type=\"submit\" class=\"bouton\" value=\"exporter le catalogue\">";
    
    
    
    
    echo "</div></form>";
    
    
    
    
    }
    
    
    
    
    Function TrimExt( $Src ) 
    
    
    { 
    
    
     $Src = ereg_replace( "(\r\n){0,15}$", "", $Src ); 
    
    
     $Src = ereg_replace( "^(\r\n){0,15}", "", $Src ); 
    
    
     $Src = ereg_replace( "(\n){0,15}$", "", $Src ); 
    
    
     $Src = ereg_replace( "^(\n){0,15}", "", $Src ); 
    
    
     $Src = trim( $Src ); 
    
    
     return $Src; 
    
    
    }
    
    
    ?>

    Ou alors si quelqu'un pouvais m'adresser un fichier "propre" ?

    Merci

    Vero


  3. Merci Willy, mais je ne trouve pas de $cgv->texte

    voici mon code de la page cgv.php

    <?php 
    
    include("../configuration.inc.php");
    
    
    necessite_identification();
    
    
    necessite_priv("admin");
    
    
    $DOC_TITLE = "Gérer les conditions de vente";
    
    
    include("modeles/haut.php");
    
    
    $start = vn($_REQUEST['start']);// Détermine la variable start (début de page)
    
    
    $id = intval(vn($_REQUEST['id']));
    
    
    switch (vb($_REQUEST['mode'])) {
    
    
    	case "maj" :
    
    
    		if (sizeof($HTTP_POST_VARS) > 0) {
    
    
    		$frm = $HTTP_POST_VARS;
    
    
    		$message_erreur = valide_form_cgv($frm, $erreurs);
    
    
    		}
    
    
    		if (empty($message_erreur)) {
    
    
    		maj_cgv($HTTP_POST_VARS);
    
    
    		echo "<span class=\"normal\"><font color=\"red\" ><b>La mise à jour de vos conditions de vente a été effectuée.</b></font></span><p></p>";
    
    
    		}
    
    
    		if (!empty($message_erreur)) {
    
    
    		echo "<span class=\"normal\"><font color=\"red\" ><b>Attention, votre formulaire est incomplet.</b></font></span><p></p>";
    
    
    		}
    
    		affiche_formulaire_modif_cgv();
    
    		break;
    
    
    	default :
    
    		affiche_formulaire_modif_cgv();
    
    		break;
    
    }
    
    
    include("modeles/bas.php");
    
    
    /******************************************************************************
    
     * FONCTIONS
    
     *****************************************************************************/
    
    
    function affiche_formulaire_modif_cgv() {
    
      /* Affiche le formulaire de modification pour le cgv sélectionné */
    
    
    	global $frm,$rubrique_options;
    
    
    	/* Charge les informations du cgv */
    
    	$qid = mysql_query("SELECT * FROM peel_cgv	WHERE id = 1");
    
    
    	$frm = mysql_fetch_array($qid);
    
    
    	$frm['nouveau_mode'] = "maj";
    
    
    	$frm['normal_bouton'] = "Sauvegarder changements";
    
    
    	affiche_formulaire_cgv();
    
    }
    
    
    function affiche_formulaire_cgv() {
    
    	GLOBAL $frm;
    
    	GLOBAL $id;
    
    	GLOBAL $rubrique_options;
    
    	GLOBAL $wwwroot;
    
    	GLOBAL $message_erreur;
    
    	GLOBAL $erreurs;
    
    	GLOBAL $repertoire_images;
    
    	$marqueur_erreur = "<font color=RED>".htmlspecialchars("=>")."</font>";
    
    	?>
    
    		<form name="entryform" method="post" action="<?php echo $_SERVER['PHP_SELF']?>?start=0" enctype="multipart/form-data">
    
    		<input type="hidden" name="mode" value="<?php echo $frm['nouveau_mode']?>" />
    
    		<input type="hidden" name="id" value="<?php echo $frm['id']?>" />
    
    		<table border="0" cellpadding="0" cellspacing="1" width="740">
    
    <tr><td height="1" bgcolor="#336699"><img src="<?php echo $wwwroot?><?php echo $wwwroot?>/images/blank.gif" height="1" alt="" /></td></tr>		
    
    <tr bgcolor="#eeeeee">
    
    	<td class="label">Modifier les conditions générales de vente (OBLIGATOIRES DANS LE CADRE DE LA LOI SUR L'ECONOMIE NUMERIQUE)</td>
    
    </tr>
    
    <tr><td height="1" bgcolor="#336699"><img src="<?php echo $wwwroot?><?php echo $wwwroot?>/images/blank.gif" height="1" alt="" /></td></tr>		
    
    		<tr valign="top" >
    
    			<td>
    
    			<table class="normal" border="0" width="100%">
    
    			<?php
    
    
    				foreach ($_SESSION['lng'] as $lng) {
    
    
    				?>
    
    				<tr><td colspan="2" class="bloc">BLOC DE LANGUE <?echo strtoupper($lng) ?></td><tr>
    
    
    				<tr>
    
    					<td class="normal" colspan="2"><font color="red"><b>Titre *</b></font>:
    
    					<?php if (!empty($erreurs['titre_fr'])) {echo $marqueur_erreur." ".$message_erreur['titre_fr']; }?></td>
    
    				</tr>
    
    				<tr>
    
    					<td colspan="2"><input style="width:100%" class="formulaire1" type="text" name="titre_<?echo $lng?>" size="50" value="<?php echo stripslashes(vb($frm['titre_'.$lng.'']))?>" /></td>
    
    				</tr>
    
    				<tr valign="top">
    
    					<td class="label" colspan="2">Texte complet des conditions de vente :</td>
    
    				</tr>
    
    				<tr valign="top">
    
    					<td class="normal" colspan="2">
    
    					<input type="hidden" ame="p_format" tabindex="2" id="p_format" class="formulaire1" value="html">
    
    <p>
    
    <textarea style="width: 100%"  name="texte_<?echo $lng?>" id="texte_<?echo $lng?>" class="formulaire1" cols="54" rows="20"><?php echo stripslashes(vb($frm['texte_'.$lng.'']))?></textarea>
    
     </p>
    
     <script src="<?php echo  $wwwroot?>/lib/js/toolbar.js" type="text/javascript"></script>
    
     <script type="text/javascript">
    
     if (document.getElementById) {
    
    		var tb = new dcToolBar(document.getElementById('texte_<?echo $lng?>'),
    
    		document.getElementById('p_format'),'images/');
    
    		tb.btStrong('Forte emphase');
    
    		tb.btEm('Emphase');
    
    		tb.btIns('Inséré');
    
    		tb.btDel('Supprimé');
    
    		tb.btQ('Citation en ligne');
    
    		tb.btCode('Code');
    
    		tb.addSpace(10);
    
    		tb.btBr('Saut de ligne');
    
    		tb.addSpace(10);
    
    		tb.btBquote('Bloc de citation');
    
    		tb.btPre('Texte préformaté');
    
    		tb.btList('Liste non ordonnée','ul');
    
    		tb.btList('Liste ordonnée','ol');
    
    		tb.addSpace(10);
    
    		tb.btLink('Lien',
    
    			'URL ?',
    
    			'Langue ?',
    
    			'fr');
    
    		tb.btImgLink('Image externe',
    
    			'URL ?');
    
    		tb.addSpace(10);
    
    		tb.draw('Vous pouvez utiliser les raccourcis suivants pour enrichir votre présentation.');
    
    	}
    
    	</script>
    
    					</td>
    
    				</tr>
    
    				<?php } ?>
    
    				<tr>
    
    					<td colspan="2"><input class="bouton" type="submit" value="<?php echo $frm['normal_bouton'] ?>" /></td>
    
    				</tr>
    
    				</table>
    
    			</td>
    
    		</tr>
    
    		</table>
    
    		</form>
    
    	<?php 
    
    }
    
    
    function maj_cgv($frm) {
    
    
    	$sql = "
    
    	UPDATE peel_cgv SET date_maj = now()";
    
    
    	foreach ($_SESSION['lng'] as $lng) {
    
    
    	$sql .= ",titre_".$lng." = '".htmlspecialchars($frm['titre_'.$lng.''], ENT_QUOTES)."'";
    
    	$sql .= ",texte_".$lng." = '".htmlspecialchars($frm['texte_'.$lng.''], ENT_QUOTES)."'";
    
    
    	}
    
    
    	$sql .= "WHERE id = 1";
    
    
    	$qid = mysql_query($sql);
    
    
    }
    
    
    
    
    function valide_form_cgv(&$frm, &$erreurs) {
    
    
    	$erreurs = array();
    
    	$msg = array();
    
    
    	if (empty($frm['titre_fr'])) {
    
    		$erreurs['titre_fr'] = true;
    
    		$msg['titre_fr'] = " Vous devez insérer un titre français pour vos conditions de vente.";
    
    
    	} 
    
    
    	return $msg;
    
    }
    
    ?>

    ainsi verras-tu mieux ?

    Merci de ton aide

    Vero


  4. Bonjour,

    Je suis inscrite sous peu sur web-marchand / le guide.com, et je constate avec plaisir que mes produits apparaissent en ligne lors de recherches.. Par contre il n'y a pas d'image ou de photos. Comment procéder pour leur affichage? Le lien vers l'exportateur de catalogue ne ramène-t-il pas vers l'hébergement des images?

    En effet, selon le service, je les ai contacté et voici leur réponse:

    Cet après midi, réponse du service:

    Bonjour,

    Voici un exemple d'url image dans votre catalogue produits :

    http://www.MONSITE.com/administrer/upload/...PEEL_w2Q4MQ.jpg

    Cette url amène sur une page d'erreur il n'est donc pas possible de la prendre en compte pour afficher vos images.

    Si vous veniez à corriger ce problème vos images seront en ligne à la mise à jour de nos sites qui suivra.

    Quelqu'un a t-il une idée sur la source de ce problème ?

    Vero


  5. Bonjour,

    j'ai depuis quelque temps des difficultés visuelles avec certaines couleurs. Et cet après midi, dans le back office, je galère. Je voudrais juste changer la couleur du survol dans le back office du menu.

    J'ai reussi pour celle de:

    Accueil Back Office

    Accueil site web

    Expand All | Collapse All

    dans le fichier css (p7tmfront.css), mais n'y arrive pas à trouver le code hexa à changer pour le survol du menu déroulant en dessous (ou il y a les configurations, gestions etc)

    Quelqu'un aurait-il une info pour me reposer les yeux ?

    Je cherche à mettre une couleur plus sombre.

    Merci

    Vero


  6. Après une recherche, j'ai trouvé cela sur le forum:

    pour corriger le problème de l'éditeur de la page "conditions de vente" par exemple, il faut remplacer dans le fichier .../cgv.php (en ligne 25)

    <?php echo nl2br(stripslashes($cgv->texte)); ?>

    par

    <?php echo nl2br(html_entity_decode(stripslashes($cgv->texte))); ?>

    Faire pareil pour les autres pages qui ont des éditeurs qui ne fonctionnent pas.

    Je vais tester

    Vero

Twitter Advisto ecommerce

Facebook PEEL Shopping