コード例 #1
0
ファイル: fiche_produit.php プロジェクト: felicia-c/apero
        //}
    }
    //echo '<input type="hidden" name="taille_stock" value="'.$ligne_taille_stock['id_taille_stock'].'" />';
    echo '</select>';
    echo '<label for="quantite">Quantité </label>';
    echo '<select id="quantite" name="quantite" class="form-control"  >';
    for ($i = 1; $i <= 10; $i++) {
        echo '<option value="' . $i . '">' . $i . '</option>';
    }
    echo '</select>';
    echo '<input type="submit" name="ajout_panier" value="Ajouter au panier" class="button"  >';
    echo '</form><br />';
    echo '</div>';
    echo '<p><br /><strong>Référence:</strong> ' . $mon_produit['reference'] . ' - <strong>Collection:</strong> ' . $mon_produit['categorie'] . '</p>';
    echo '<p><strong>Couleur:</strong> ' . $mon_produit['couleur'] . '</p>';
    echo '<p><strong>Description:</strong> ' . $mon_produit['description'] . '</p><br /><br /><hr />
	<h3 class="orange">Apéros proposés avec ce T-shirt:</h3>';
    $req = "SELECT bar.id_bar, bar.nom_bar, bar.cp, promo_bar.description, promo_bar.date_debut, promo_bar.date_fin, promo_bar.id_bar, promo_bar.categorie_produit, bar.statut FROM promo_bar INNER JOIN bar ON bar.id_bar=promo_bar.id_bar WHERE promo_bar.categorie_produit='{$mon_produit['categorie']}' AND (promo_bar.date_fin > NOW() AND bar.statut!='0') ORDER BY promo_bar.date_debut";
    affichePromoBar($req);
    //lien de retour vers la categorie du produit
    echo '<br /><a href="boutique.php?action=tri_categorie&categorie=' . str_replace('#', '', $mon_produit['categorie']) . '"> Retour à la Collection ' . $mon_produit['categorie'] . '</a> ';
} else {
    echo "OUPS ! Il y a un petit soucis !";
}
?>
	</div>
	<br />
	<br />
	  
  <?php 
require_once "inc/footer.inc.php";
コード例 #2
0
ファイル: fiche_bar.php プロジェクト: felicia-c/apero
                $msg .= '<div class="msg_success" ><h4>Merci pour votre évaluation!</h4></div>';
                unset($_POST);
                echo '<meta http-equiv="refresh" content="2;URL=' . RACINE_SITE . 'fiche_bar.php?id_bar=' . $_GET['id_bar'] . '">';
            }
        }
    } elseif (!isset($_GET['id_bar'])) {
        $msg .= '<div class="msg_erreur" ><h4>Une erreur est survenue</h4></div>';
    }
}
require_once 'inc/header.inc.php';
echo '<div class="box_info">';
echo $msg;
if (isset($_GET['id_bar'])) {
    $id_bar = filter_input(INPUT_GET, 'id_bar', FILTER_SANITIZE_NUMBER_INT);
    $req = "SELECT * FROM bar WHERE id_bar = '{$id_bar}'";
    //afficheBar($req);
    if (afficheBar($req)) {
        echo '<hr />
			<h2 class="tomato msg_apero">Apéros proposés par ce bar</h2>';
        $req_promo = "SELECT * FROM promo_bar WHERE id_bar='{$id_bar}' AND date_fin > NOW() ORDER BY date_debut";
        affichePromoBar($req_promo);
    }
}
echo '<br /><br />';
echo '<hr /><div id="boxnewsletter">';
formulaireNewsletter();
inscriptionNewsletter($msg);
echo '</div>
<br /><br />';
echo '</div>';
require_once 'inc/footer.inc.php';