| 3 |
lars |
1 |
<?
|
|
|
2 |
function basket()
|
|
|
3 |
{
|
|
|
4 |
/* ############################# */
|
|
|
5 |
/* Abbrechen wenn Warenkorb leer */
|
|
|
6 |
/* ############################# */
|
|
|
7 |
// Titeltemplate auslesen
|
|
|
8 |
$template = file_get_contents("templates/basket/1/1.htm");
|
|
|
9 |
if ($_SESSION[SHOP][BASKET] == array())
|
|
|
10 |
{
|
|
|
11 |
$msg[title]=$_SESSION[INI][basket][emptyMsg];
|
|
|
12 |
echo templateContent($msg, $template);
|
|
|
13 |
return ;
|
|
|
14 |
}
|
|
|
15 |
else
|
|
|
16 |
{
|
|
|
17 |
$msg[title]="Warenkorb";
|
|
|
18 |
echo templateContent($msg, $template);
|
|
|
19 |
}
|
|
|
20 |
|
|
|
21 |
basketContent("templates/basket/");
|
|
|
22 |
|
|
|
23 |
// Titeltemplate auslesen
|
|
|
24 |
$template = file_get_contents("templates/basket/1/1.htm");
|
|
|
25 |
|
|
|
26 |
// Gesamtsumme ausgeben
|
|
|
27 |
$msg[title]="Gesamtsumme (incl. 16 % MwSt.: ".numberFormat(getBasketSummeMWST())." €)";
|
|
|
28 |
$msg[summe]=numberFormat(getBasketSumme())." €";
|
|
|
29 |
echo templateContent($msg, $template);
|
|
|
30 |
|
|
|
31 |
// Gewicht ausgeben
|
|
|
32 |
$msg[title]="Gewicht";
|
|
|
33 |
$msg[summe]=numberFormat(getBasketGewicht())."kg";
|
|
|
34 |
//echo templateContent($msg, $template);
|
|
|
35 |
unset($msg);
|
|
|
36 |
|
|
|
37 |
// Versandoptionen lesen und ausgeben
|
|
|
38 |
$vTemplate = file_get_contents("templates/basket/7/7.htm");
|
|
|
39 |
$buffer=array();
|
|
|
40 |
|
|
|
41 |
foreach(getVersandItems() as $vItem)
|
|
|
42 |
{
|
|
|
43 |
$vItem_Beschreibung = $vItem[beschr];
|
|
|
44 |
$vItem[preis] = numberFormat($vItem[preis])."€";
|
|
|
45 |
$buffer[] = templateContent($vItem, $vTemplate);
|
|
|
46 |
}
|
|
|
47 |
|
|
|
48 |
if ($_SESSION[SHOP][Lieferadresse] == "true")
|
|
|
49 |
{
|
|
|
50 |
$Land=$_SESSION[SHOP][buy][Persdata][liefer_Land];
|
|
|
51 |
}
|
|
|
52 |
else
|
|
|
53 |
{
|
|
|
54 |
$Land=$_SESSION[SHOP][buy][Persdata][Land];
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
$msg[title] = "Mögliche Versandarten für ".getCountryByID($Land)." (inkl. 16% MwSt.):<br>";
|
|
|
58 |
$msg[Versand] = "<ul>".implode("",$buffer)."</ul>";
|
|
|
59 |
if (count($buffer) == 1)
|
|
|
60 |
{
|
|
|
61 |
$msg[Versand].= "<p>".$vItem_Beschreibung."</p>";
|
|
|
62 |
}
|
|
|
63 |
echo templateContent($msg, $template);
|
|
|
64 |
unset($msg);
|
|
|
65 |
|
|
|
66 |
// Buttonleiste ausgeben
|
|
|
67 |
$msg[title]="<a href=\"javascript:history.back();\" onMouseOut=\"MM_swapImgRestore()\" onMouseOver=\"MM_swapImage('bt_back','','/images/webelemente/buttons/bt_zurueck_f2.gif',1); window.status=''; return true;\"><img name=\"bt_back\" src=\"/images/webelemente/buttons/bt_zurueck.gif\" alt=\"Zurück\"></a>";
|
|
|
68 |
$msg[summe]="<a href=buy.html onMouseOut=\"MM_swapImgRestore()\" onMouseOver=\"MM_swapImage('bt_kasse','','/images/webelemente/buttons/bt_wkasse_f2.gif',1); window.status=''; return true;\"><img name=\"bt_kasse\" src=\"/images/webelemente/buttons/bt_wkasse.gif\" alt=\"Zur Kasse\"></a>";
|
|
|
69 |
echo templateContent($msg, $template);
|
|
|
70 |
}
|
|
|
71 |
basket();
|
|
|
72 |
?>
|