Mail faal

Gestart doorMikeb89 reacties548 weergaven

90 berichten · pagina 5 van 6

Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
$_POST[mob]

Lees mijn link eens, de index van de $_POST moet tussen single-quotes;
$_POST[mob]

Logisch dat je maar 1 product ziet, ik mis een while()
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Ja maar die gegevens worden dan niet weergegeven.
Eerst deden die gegevens het wel, en nu plaatst hij alleen de producten confused
toevoeging op 2 juli 2012, 14:24:35:
De rest zal ik eens bekijken wink
toevoeging op 2 juli 2012, 15:08:21:
Mmm, ik heb geen idee waar ik die while moet plaatsen.

toevoeging op 2 juli 2012, 15:09:48:
de rest staat trouwens in die singel quotes wat je net zei.
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
niemand?
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
Het factuurgedeelte, waar alle producten in staan, daar hoor een whileloop omheen.
je wilt toch de producten ophalen die een gebruiker geeft besteld?
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Ja klopt. Het moet een factuur worden. Ik heb alleen geen idee waar ik die while moet neerzetten.
Ik heb meer dan een uur op internet gezocht van de week maar ik kom er niet uit. Zou je dat stukje misschien voor mij kunnen doen? De rest kan ik dan zelf wel denk ik. wink
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
Je moet het stukje HTML waarin de producten staan aanpassen tot een foreach().
Ik heb niet veel tijd om de hele code te bekijken, maar het komt op het volgende neer:

<table border="0">
<tr>
<th width="10%">Artikelnummer</th>
<th width="40%">Naam</th>
<th width="20%">Prijs<small>(excl. BTW)</small></th>
<th width="10%">Aantal</th>
<th width="20%">Totaal<small>(excl. BTW)</small></th>
</tr>
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/foreach"]foreach[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]] as[/COLOR] [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700]) {[/COLOR]
?>
<tr>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]artikelnummer[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]prijs[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$cart[/COLOR][COLOR= #007700])[/COLOR] ?> stuks</th>
<th>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]totaal[/COLOR][COLOR= #007700]][/COLOR] ?></th>
</tr>
[COLOR= #0000BB]<?php[/COLOR] 
[COLOR= #007700]}[/COLOR]
?>


met $_POST alleen kom je niet ver. Je wilt immers niet alles uit de $_POST halen. De prijzen al helemaal niet wink.
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Bedankt. Ik ga het eens proberen.

toevoeging op 4 juli 2012, 13:32:21:
Het werkt natuurlijk niet. confusedDat komt omdat het een HTML gedeelte is en het moet dus met . . Dus ik weet niet hoe ik die foreach daarin moet verwerken.

toevoeging op 4 juli 2012, 13:33:54:
Ik heb nu dit:

<table border="0">
<tr>
<th width="10%">Artikelnummer</th>
<th width="40%">Naam</th>
<th width="20%">Prijs<small>(excl. BTW)</small></th>
<th width="10%">Aantal</th>
<th width="20%">Totaal<small>(excl. BTW)</small></th>
</tr>
. foreach($_SESSION[cart] as $cart { .
<tr>
    <th>. $cart[serial] .</th>
    <th>. $cart[name] .</th>
    <th>&euro; . $cart[price] .</th>
    <th>. count($cart) . stuks</th>
    <th>&euro; . $totalpr .</th>
    </tr>
    [COLOR= #0000BB]<?php[/COLOR]
    [COLOR= #007700]}[/COLOR]
    ?>


Daar zal vast geen reet van kloppen. yummie
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
tussentijds even je PHP-blok afsluiten. Zie mijn voorbeeld.
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
en die totaal is het aantal stuks x de prijs. Hoe kan ik dat er het beste in verwerken?

toevoeging op 4 juli 2012, 16:26:43:
Parse error: syntax error, unexpected cart (T_STRING) in /home/blablablabla.php on line 183

krijg ik nu trouwens ook nog. dus hij herkent de sessie niet denk ik ?
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
Denk eerder dat de code niet klopt, gezien het een syntax-error is.
0
Berichten
35.796
Reputatie
1
Punten
0,00
Lid sinds
Laatst gezien
Post je code eens?
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Lennard de meester php-scripter komt erbij biggrin
Okee hier is mijn code, in spoiler omdat hij anders wel heeuwwwl lang wordt. yummie
Spoiler tonen
[COLOR= #0000BB]<?php[/COLOR]
    [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"includes/db.php"[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"includes/functions.php"[/COLOR][COLOR= #007700]);[/COLOR]
    
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]delete[/COLOR] [COLOR= #007700]&&[/COLOR] [COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pid[/COLOR][COLOR= #007700]]>[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700]){[/COLOR]
        remove_product[COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pid[/COLOR][COLOR= #007700]]);
    }[/COLOR]
    [URL="http://www.php.net/else"]else[/URL] [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]clear[/COLOR][COLOR= #007700]){[/COLOR]
        [URL="http://www.php.net/unset"]unset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);
    }[/COLOR]
    [URL="http://www.php.net/else"]else[/URL] [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]update[/COLOR][COLOR= #007700]){[/COLOR]
        [COLOR= #0000BB]$max[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);[/COLOR]
        [URL="http://www.php.net/for"]for[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]$max[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]++){[/COLOR]
            [COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]productid[/COLOR][COLOR= #007700]];[/COLOR]
            [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/intval"]intval[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]product[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]]);[/COLOR]
            [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]>[/COLOR][COLOR= #0000BB]0[/COLOR] [COLOR= #007700]&&[/COLOR] [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]<=[/COLOR][COLOR= #0000BB]9999[/COLOR][COLOR= #007700]){[/COLOR]
                [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]qty[/COLOR][COLOR= #007700]]=[/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700];
            }[/COLOR]
            [URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700]){[/COLOR]
                                [COLOR= #0000BB]$msg[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #DD0000]U kunt geen negatief aantal bestellen.[/COLOR][COLOR= #007700];
                       }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
                [COLOR= #0000BB]$msg[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #DD0000]U kunt maximaal 9999 eenzelfde producten bestellen.[/COLOR][COLOR= #007700];
            }
        }
    }[/COLOR]
?>
[COLOR= #0000BB]<?php[/COLOR]            
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/is_array"]is_array[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]])){[/COLOR]
                [COLOR= #0000BB]$max[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);[/COLOR]
                [URL="http://www.php.net/for"]for[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]$max[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]++){[/COLOR]
                    [COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]productid[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]qty[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$pname[/COLOR][COLOR= #007700]=[/COLOR]get_product_name[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]);[/COLOR]
                    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]==[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700])[/COLOR] [URL="http://www.php.net/continue"]continue[/URL][COLOR= #007700];[/COLOR]

                        [COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]=[/COLOR]get_price[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$price[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
                        [COLOR= #0000BB]$totalpr[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700];[/COLOR]
                        [COLOR= #0000BB]$total[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$totalpr[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$inclbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]1.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$incl[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$inclbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);
                }[/COLOR]
                        [COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]=[/COLOR]get_order_total[COLOR= #007700]();[/COLOR]
            [COLOR= #0000BB]$ordprice[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$ordbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]0.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$ordbtw2[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$ordinclbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]1.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$ordincl[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordinclbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);
            }[/COLOR]
            [URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
                [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"<tr><td>U heeft geen producten besteld.</td></tr>"[/COLOR][COLOR= #007700];
            }[/COLOR]
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> 
    <link rel="stylesheet" type="text/css" href="style.css" />
    <script type="javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
    <script type="text/javascript">
    function openmenu(id) {
        if(document.getElementById(id).style.display == "block")
        {        
            document.getElementById(id).style.display = "none";
        }
        else
        {
            document.getElementById(id).style.display = "block";
        }
    }
    </script>
    <title>Cameramast.com - Afrekenen</title>
</head>
<body>

    <div id="container">
    
        <div class="menubutton_hl"><a href="index">Home</a></div>
        <div class="menubutton"><a href="shop_vast">Vaste mast</a></div>
        <div class="menubutton"><a href="shop_kantel">Kantelbare mast</a></div>
        <div class="menubutton"><a href="shop_toebehoren">Toebehoren</a></div>
        <div class="menubutton"><a href="contact">Contact</a></div>
        
        <div style="clear: both;"></div>
        
        <div id="header">Cameramast.com</div>
        
        <div id="content">
        
            <div id="links">
        
                <div class="titel">Afrekenen<sub style="float: right; margin-top: 13px; margin-right: 2px; font-size: 11px;"> </sub></div>
                
                <div class="content">
[COLOR= #0000BB]<?[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SERVER[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]REQUEST_METHOD[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"POST"[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<br><br>"[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$user[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]ref[/COLOR][COLOR= #007700]];[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]voornaam[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen voornaam ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]achternaam[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]adres[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen adres ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]postcode[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]plaats[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]land[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen land ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]tel[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR] AND [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]mob[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen telefoonnummer of mobiele nummer ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]email[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen e-mail adres ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kvk[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen Kamer van koophandel / Chambers of Commerce ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]btw[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen BTW-nummer ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"Uw bestelling is succesvol ontvangen<br />Controleer uw email voor de factuur.<br />Let op! Refresh deze pagina niet."[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$bedrijf[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR]bedrijf[COLOR= #007700]];[/COLOR]
[COLOR= #FF8000]// subject[/COLOR]
[COLOR= #0000BB]$subject[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]Uw bestelling op Cameramast.com[/COLOR][COLOR= #007700];[/COLOR]

[COLOR= #FF8000]// message[/COLOR]
[COLOR= #0000BB]$message[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]
<html>
<head>
  <title>Bestelling op Cameramast.com</title>
</head>
<body>
  <p>Geachte heer/mevrouw,<br />
<br />
Bedankt voor de bestelling bij Cameramast.com<br />
Hieronder vindt u een factuur met uw gegevens en de bestelde producten.<br />
<br /></p>
<p><b>Gegevens:</b></p><br />
  <table border="0">
    <tr>
      <th>Bedrijf: </th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]bedrijf[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Voornaam: </th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]voornaam[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Achternaam:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]achternaam[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Adres:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]adres[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Postcode + Plaats:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]postcode[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000] te [/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]plaats[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Land:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]land[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>E-mail adres:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]email[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Telefoonnummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]tel[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Mobiele nummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]mob[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Kamer van Koophandel / CCI:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kvk[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>BTW-nummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]btw[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
  </table><br /><br />
<p><b>Factuur:</b></p>
<table border="0">
<tr>
<th width="10%">Artikelnummer</th>
<th width="40%">Naam</th>
<th width="20%">Prijs<small>(excl. BTW)</small></th>
<th width="10%">Aantal</th>
<th width="20%">Totaal<small>(excl. BTW)</small></th>
</tr>
<?php
foreach($_SESSION[[/COLOR]cart[COLOR= #DD0000]] as $cart) {
?>
<tr>
<th><?php echo  $cart[[/COLOR]serial[COLOR= #DD0000]] ?></th>
<th><?php echo  $cart[[/COLOR]name[COLOR= #DD0000]] ?></th>
<th>&euro; <?php echo  $cart[[/COLOR]price[COLOR= #DD0000]] ?></th>
<th>[/COLOR][COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$cart[/COLOR][COLOR= #007700])[/COLOR] ?> stuks</th>
<th>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]totaal[/COLOR][COLOR= #007700]][/COLOR] ?></th>
</tr>
[COLOR= #0000BB]<?php[/COLOR] 
[COLOR= #007700]}[/COLOR]
?>
<tr><th></th><th></th></tr>
                <tr><th><b>Totaal:</b><br /><b>19% BTW:</b><br /><b>Totaal:</b></th><th><b>&euro; . $ordprice .<small>(excl. BTW)</small><br /><b>&euro; &nbsp;&nbsp; .$ordbtw2.</b><br /><b>&euro; . $ordincl .<small>(incl. BTW)</small></b></th>  
</table>
</body>
</html>
;


// To send HTML mail, the Content-type header must be set
$headers  = MIME-Version: 1.0 . "rn";
$headers .= Content-type: text/html; charset=iso-8859-1 . "rn";

// Additional headers
$headers .= From: Cameramast.com <info@cameramast.com> . "rn";
$headers .= Bcc: HOI!!! . "rn";

// Mail it
mail($_POST[email], $subject, $message, $headers);
$customerid=mysql_insert_id();
        $date=date(Y-m-d);
        $result = mysql_query("insert into orders values(,$date,$customerid)");
                mysql_real_escape_string($result);
        $orderid=mysql_insert_id();
        
        $max=count($_SESSION[cart]);
        for($i=0;$i<$max;$i++){
            $pid=$_SESSION[cart][$i][productid];
            $q=$_SESSION[cart][$i][qty];
            $price=get_price($pid);
            $result = mysql_query("insert into order_detail values ($orderid,$pid,$q,$price)");
                      mysql_real_escape_string($result);
}}}else{
?>
    </p>
    <form name="form1" method="POST" action="">
  <div align="center">
        <h1 align="center">Afrekenen</h1>
        <table border="0" cellpadding="2px">
            <tr><td>Totaal bedrag:</td><td>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] get_order_total[COLOR= #007700]()[/COLOR]?></td></tr>
            <tr><td>* Bedrijf:</td><td><input type="text" name="bedrijf" is="bedrijf" /></td></tr>
            <tr><td>* Voornaam:</td><td><input type="text" name="voornaam" id="voornaam" /></td></tr>
            <tr><td>* Achternaam:</td><td><input type="text" name="achternaam" id="achternaam" /></td></tr>
            <tr><td>* Email:</td><td><input type="text" name="email" id="email" /></td></tr>
            <tr><td>* Adres:</td><td><input type="text" name="adres" id="adres" /></td></tr>
            <tr><td>* Postcode:</td><td><input type="text" name="postcode" id="postcode" /></td></tr>
            <tr><td>* Plaats:</td><td><input type="text" name="plaats" id="plaats" /></td></tr>
            <tr><td>* Land:</td><td><input type="text" name="land" id="land" /></td></tr>
            <tr><td>** Telefoonnummer:</td><td><input type="text" name="tel" id="tel" /></td></tr>
            <tr><td>** Mobiele nummer:</td><td><input type="text" name="mob" id="mob"/></td></tr>
            <tr><td>* Kamer van Koophandel:</td><td><input type="text" name="kvk" id="kvk" /></td></tr>
            <tr><td>* BTW-nummer:</td><td><input type="text" name="btw" id="btw" /></td></tr>
            <tr><td>&nbsp;</td><td><input type="submit" value="Bestel" /></td></tr>
        </table>
* Deze zijn verplicht in te vullen.<br />
** U kunt kiezen of u een telefoonnummer, mobiele nummer of allebei invult.
    </div>
</form>
[COLOR= #0000BB]<?php[/COLOR]
[COLOR= #007700]}[/COLOR]
?></div>
        
            </div>
        <div id="rechts">
            <div class="titel">Winkelwagen</div>
<div class="content">
[COLOR= #0000BB]<?php[/COLOR]
            [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/is_array"]is_array[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]])){[/COLOR]
                [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]    <tr bgcolor="#FFFFFF" style="font-weight:bold"></tr>[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$max[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);[/COLOR]
                [URL="http://www.php.net/for"]for[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]$max[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]++){[/COLOR]
                    [COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]productid[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]qty[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$pname[/COLOR][COLOR= #007700]=[/COLOR]get_product_name[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]);[/COLOR]
                    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]==[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700])[/COLOR] [URL="http://www.php.net/continue"]continue[/URL][COLOR= #007700];[/COLOR]
?>

<table><tr><td width="25">[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$q[/COLOR]?>x</td><td width="135">[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$pname[/COLOR]?></td><td width="40">&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] get_price[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700])*[/COLOR][COLOR= #0000BB]$q[/COLOR]?></td><td width="15"><a href="javascript:del([COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$pid[/COLOR]?>)">Del</a></td></tr></table>
            [COLOR= #0000BB]<?php[/COLOR]                    
                [COLOR= #007700]}[/COLOR]
            ?>
<b>Totaal bedrag: &euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] get_order_total[COLOR= #007700]()[/COLOR]?></b><br /><input type="button" value="Inhoud" onclick="window.location=shoppingcart"><input type="button" value="Bestel" onclick="window.location=billing"></td></tr>
        [COLOR= #0000BB]<?php[/COLOR]
            [COLOR= #007700]}[/COLOR]
            [URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
                [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"U heeft op dit moment geen producten in uw winkelwagen staan."[/COLOR][COLOR= #007700];
            }[/COLOR]
        ?>

</div>
                <div class="titel">Menu</div><br />
                <div class="content">
                
                    <div class="menu" onclick="openmenu(inhoud1)"><strong>Home</strong></div>
                    <div id="inhoud1" style="display: none;"> <a href="index">Homepage</a><br /></div>
                    
                    <div class="menu" onclick="openmenu(inhoud2)"><strong>About</strong></div>
                    <div id="inhoud2" style="display: none;"> <a href="aboutus">About us</a><br /></div>
                    
                    <div class="menu" onclick="openmenu(inhoud3)"><strong>Vaste mast</strong></div>
                    <div id="inhoud3" style="display: none;"> <a href="shop_vast">Vaste cameramasten</a><br /></div>
                    
                    <div class="menu" onclick="openmenu(inhoud4)"><strong>Kantelbare mast</strong></div>
                    <div id="inhoud4" style="display: none;"> <a href="shop_kantel">Kantelbare cameramasten</a><br /></div>
                    
                    <div class="menu" onclick="openmenu(inhoud5)"><strong>Contact</strong></div>
                    <div id="inhoud5" style="display: none;"> <a href="contact">Contact</a><br /></div>
                                
                </div>
<!--            
                <div class="titel">Zoeken op de site</div>
                <div style="margin-top: 59px; margin-bottom: 15px;"><input type="text" id="zoeken" /><br /><input type="submit" value="Start zoeken" style="margin-left: 100px;" /></div>
-->
            <div class="titel">Nieuws</div>
                <div style="margin-top: 59px; margin-bottom: 15px;">Testje ofzo</div>
            </div>
</div>

        <div id="footer">&copy;2012 Cameramast.com - Alle rechten voorbehouden - <a href="contact">Contact</a></div>
    
    </div>

</body>
</html>
0
Berichten
35.796
Reputatie
1
Punten
0,00
Lid sinds
Laatst gezien
leer eens goed uitlijnen, want dit is gewoon niet te doen joh emo
toevoeging op 4 juli 2012, 17:52:55:
En kijk eens naar de kleurtjes, dan zie je wat je fout hebt gedaan smile
0
Mikeb

Lid · Topicstarter

Berichten
6.356
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Ik weet nooit wat de beste uitlijning is en heb het bijna geheel van internet geplukt.

En die kleurtjes zeggen mij echt niks dus daarnkan ik niks mee...
0
Berichten
2.609
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Spoiler tonen
[COLOR= #0000BB]<?php[/COLOR]
    [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"includes/db.php"[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"includes/functions.php"[/COLOR][COLOR= #007700]);[/COLOR]
    
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]delete[/COLOR] [COLOR= #007700]&&[/COLOR] [COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pid[/COLOR][COLOR= #007700]]>[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700]){[/COLOR]
        remove_product[COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pid[/COLOR][COLOR= #007700]]);
    }[/COLOR]
    [URL="http://www.php.net/else"]else[/URL] [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]clear[/COLOR][COLOR= #007700]){[/COLOR]
        [URL="http://www.php.net/unset"]unset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);
    }[/COLOR]
    [URL="http://www.php.net/else"]else[/URL] [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]command[/COLOR][COLOR= #007700]]==[/COLOR][COLOR= #DD0000]update[/COLOR][COLOR= #007700]){[/COLOR]
        [COLOR= #0000BB]$max[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);[/COLOR]
        [URL="http://www.php.net/for"]for[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]$max[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]++){[/COLOR]
            [COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]productid[/COLOR][COLOR= #007700]];[/COLOR]
            [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/intval"]intval[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_REQUEST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]product[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]]);[/COLOR]
            [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]>[/COLOR][COLOR= #0000BB]0[/COLOR] [COLOR= #007700]&&[/COLOR] [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]<=[/COLOR][COLOR= #0000BB]9999[/COLOR][COLOR= #007700]){[/COLOR]
                [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]qty[/COLOR][COLOR= #007700]]=[/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700];
            }[/COLOR]
            [URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700]){[/COLOR]
                                [COLOR= #0000BB]$msg[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #DD0000]U kunt geen negatief aantal bestellen.[/COLOR][COLOR= #007700];
                       }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
                [COLOR= #0000BB]$msg[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #DD0000]U kunt maximaal 9999 eenzelfde producten bestellen.[/COLOR][COLOR= #007700];
            }
        }
    }[/COLOR]
?>
[COLOR= #0000BB]<?php[/COLOR]            
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/is_array"]is_array[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]])){[/COLOR]
                [COLOR= #0000BB]$max[/COLOR][COLOR= #007700]=[/COLOR][URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]]);[/COLOR]
                [URL="http://www.php.net/for"]for[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]<[/COLOR][COLOR= #0000BB]$max[/COLOR][COLOR= #007700];[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]++){[/COLOR]
                    [COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]productid[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$q[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #0000BB]$i[/COLOR][COLOR= #007700]][[/COLOR][COLOR= #DD0000]qty[/COLOR][COLOR= #007700]];[/COLOR]
                    [COLOR= #0000BB]$pname[/COLOR][COLOR= #007700]=[/COLOR]get_product_name[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]);[/COLOR]
                    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700]==[/COLOR][COLOR= #0000BB]0[/COLOR][COLOR= #007700])[/COLOR] [URL="http://www.php.net/continue"]continue[/URL][COLOR= #007700];[/COLOR]

                        [COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]=[/COLOR]get_price[COLOR= #007700]([/COLOR][COLOR= #0000BB]$pid[/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$price[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
                        [COLOR= #0000BB]$totalpr[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]$q[/COLOR][COLOR= #007700];[/COLOR]
                        [COLOR= #0000BB]$total[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$totalpr[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$inclbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$prijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]1.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$incl[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$inclbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);
                }[/COLOR]
                        [COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]=[/COLOR]get_order_total[COLOR= #007700]();[/COLOR]
            [COLOR= #0000BB]$ordprice[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$ordbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]0.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$ordbtw2[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$ordinclbtw[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$ordprijs[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]1.19[/COLOR][COLOR= #007700];[/COLOR]
            [COLOR= #0000BB]$ordincl[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/number_format"]number_format[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$ordinclbtw[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000].[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]);
            }[/COLOR]
            [URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
                [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"<tr><td>U heeft geen producten besteld.</td></tr>"[/COLOR][COLOR= #007700];
            }[/COLOR]
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> 
    <link rel="stylesheet" type="text/css" href="style.css" />
    <script type="javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
    <script type="text/javascript">
    function openmenu(id) {
        if(document.getElementById(id).style.display == "block")
        {        
            document.getElementById(id).style.display = "none";
        }
        else
        {
            document.getElementById(id).style.display = "block";
        }
    }
    </script>
    <title>Cameramast.com - Afrekenen</title>
</head>
<body>

    <div id="container">
    
        <div class="menubutton_hl"><a href="index">Home</a></div>
        <div class="menubutton"><a href="shop_vast">Vaste mast</a></div>
        <div class="menubutton"><a href="shop_kantel">Kantelbare mast</a></div>
        <div class="menubutton"><a href="shop_toebehoren">Toebehoren</a></div>
        <div class="menubutton"><a href="contact">Contact</a></div>
        
        <div style="clear: both;"></div>
        
        <div id="header">Cameramast.com</div>
        
        <div id="content">
        
            <div id="links">
        
                <div class="titel">Afrekenen<sub style="float: right; margin-top: 13px; margin-right: 2px; font-size: 11px;"> </sub></div>
                
                <div class="content">
[COLOR= #0000BB]<?[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SERVER[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]REQUEST_METHOD[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"POST"[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<br><br>"[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$user[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]ref[/COLOR][COLOR= #007700]];[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]voornaam[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen voornaam ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]achternaam[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]adres[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen adres ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]postcode[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]plaats[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen achternaam ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]land[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen land ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]tel[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR] AND [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]mob[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen telefoonnummer of mobiele nummer ingevuld"[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]email[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen e-mail adres ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kvk[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen Kamer van koophandel / Chambers of Commerce ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]btw[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"U heeft geen BTW-nummer ingevuld."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"Uw bestelling is succesvol ontvangen<br />Controleer uw email voor de factuur.<br />Let op! Refresh deze pagina niet."[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$bedrijf[/COLOR][COLOR= #007700]=[/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR]bedrijf[COLOR= #007700]];[/COLOR]
[COLOR= #FF8000]// subject[/COLOR]
[COLOR= #0000BB]$subject[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]Uw bestelling op Cameramast.com[/COLOR][COLOR= #007700];[/COLOR]

[COLOR= #FF8000]// message[/COLOR]
[COLOR= #0000BB]$message[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]
<html>
<head>
  <title>Bestelling op Cameramast.com</title>
</head>
<body>
  <p>Geachte heer/mevrouw,<br />
<br />
Bedankt voor de bestelling bij Cameramast.com<br />
Hieronder vindt u een factuur met uw gegevens en de bestelde producten.<br />
<br /></p>
<p><b>Gegevens:</b></p><br />
  <table border="0">
    <tr>
      <th>Bedrijf: </th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]bedrijf[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Voornaam: </th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]voornaam[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Achternaam:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]achternaam[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Adres:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]adres[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Postcode + Plaats:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]postcode[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000] te [/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]plaats[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Land:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]land[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>E-mail adres:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]email[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Telefoonnummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]tel[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Mobiele nummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]mob[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>Kamer van Koophandel / CCI:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kvk[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
    <tr>
      <th>BTW-nummer:</th><th>[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]btw[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]</th>
    </tr>
  </table><br /><br />
<p><b>Factuur:</b></p>
<table border="0">
<tr>
<th width="10%">Artikelnummer</th>
<th width="40%">Naam</th>
<th width="20%">Prijs<small>(excl. BTW)</small></th>
<th width="10%">Aantal</th>
<th width="20%">Totaal<small>(excl. BTW)</small></th>
</tr>[/COLOR][COLOR= #007700];[/COLOR] ?>
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/foreach"]foreach[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]cart[/COLOR][COLOR= #007700]] as[/COLOR] [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700]) {[/COLOR]
?>
<tr>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]serial[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]name[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL]  [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]price[/COLOR][COLOR= #007700]][/COLOR] ?></th>
<th>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [URL="http://www.php.net/count"]count[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$cart[/COLOR][COLOR= #007700])[/COLOR] ?> stuks</th>
<th>&euro; [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$cart[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]totaal[/COLOR][COLOR= #007700]][/COLOR] ?></th>
</tr>
[COLOR= #0000BB]<?php[/COLOR] 
[COLOR= #007700]}[/COLOR]
?>[COLOR= #0000BB]<?php[/COLOR] 
[COLOR= #007700]<[/COLOR]tr[COLOR= #007700]><[/COLOR]th[COLOR= #007700]><[/COLOR]/th[COLOR= #007700]><[/COLOR]th[COLOR= #007700]><[/COLOR]/th[COLOR= #007700]><[/COLOR]/tr[COLOR= #007700]>
                <[/COLOR]tr[COLOR= #007700]><[/COLOR]th[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>[/COLOR]Totaal[COLOR= #007700]:<[/COLOR]/b[COLOR= #007700]><[/COLOR]br /[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>[/COLOR][COLOR= #0000BB]19[/COLOR][COLOR= #007700]%[/COLOR] BTW[COLOR= #007700]:<[/COLOR]/b[COLOR= #007700]><[/COLOR]br /[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>[/COLOR]Totaal[COLOR= #007700]:<[/COLOR]/b[COLOR= #007700]><[/COLOR]/th[COLOR= #007700]><[/COLOR]th[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>&[/COLOR]euro[COLOR= #007700];[/COLOR] [COLOR= #DD0000]. $ordprice .[/COLOR][COLOR= #007700]<[/COLOR]small[COLOR= #007700]>([/COLOR]excl[COLOR= #007700].[/COLOR] BTW[COLOR= #007700])<[/COLOR]/small[COLOR= #007700]><[/COLOR]br /[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>&[/COLOR]euro[COLOR= #007700]; &[/COLOR]nbsp[COLOR= #007700];&[/COLOR]nbsp[COLOR= #007700];[/COLOR] [COLOR= #DD0000].$ordbtw2.[/COLOR][COLOR= #007700]<[/COLOR]/b[COLOR= #007700]><[/COLOR]br /[COLOR= #007700]><[/COLOR]b[COLOR= #007700]>&[/COLOR]euro[COLOR= #007700];[/COLOR] [COLOR= #DD0000]. $ordincl .[/COLOR][COLOR= #007700]<[/COLOR]small[COLOR= #007700]>([/COLOR]incl[COLOR= #007700].[/COLOR] BTW[COLOR= #007700])<[/COLOR]/small[COLOR= #007700]><[/COLOR]/b[COLOR= #007700]><[/COLOR]/th[COLOR= #007700]>  
<[/COLOR]/table[COLOR= #007700]>
<[/COLOR]/body[COLOR= #007700]>
<[/COLOR]/html[COLOR= #007700]>[/COLOR]
[COLOR= #DD0000]; 


// To send HTML mail, the Content-type header must be set
$headers  = [/COLOR]MIME[COLOR= #007700]-[/COLOR]Version[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]1.0[/COLOR][COLOR= #DD0000] . "rn";
$headers .= [/COLOR]Content[COLOR= #007700]-[/COLOR]type[COLOR= #007700]:[/COLOR] text/html[COLOR= #007700];[/COLOR] charset[COLOR= #007700]=[/COLOR]iso[COLOR= #007700]-[/COLOR][COLOR= #0000BB]8859[/COLOR][COLOR= #007700]-[/COLOR][COLOR= #0000BB]1[/COLOR][COLOR= #DD0000] . "rn";

// Additional headers
$headers .= [/COLOR]From[COLOR= #007700]:[/COLOR] Cameramast[COLOR= #007700].[/COLOR]com [COLOR= #007700]<[/COLOR]info[COLOR= #007700]@[/COLOR]cameramast[COLOR= #007700].[/COLOR]com[COLOR= #007700]>[/COLOR][COLOR= #DD0000] . "rn";
$headers .= [/COLOR]Bcc[COLOR= #007700]:[/COLOR] HOI[COLOR= #007700]!!![/COLOR][COLOR= #DD0000] . "rn";

// Mail it
mail($_POST[email], $subject, $message, $headers);
$customerid=mysql_insert_id();
        $date=date([/COLOR]Y[COLOR= #007700]-[/COLOR]m[COLOR= #007700]-[/COLOR]d[COLOR= #DD0000]);
        $result = mysql_query("insert into orders values(,[/COLOR][COLOR= #0000BB]$date[/COLOR][COLOR= #DD0000],[/COLOR][COLOR= #0000BB]$customerid[/COLOR][COLOR= #DD0000])");
                mysql_real_escape_string($result);
        $orderid=mysql_insert_id();
        
        $max=count($_SESSION[[/COLOR]cart[COLOR= #DD0000]]);
        for($i=0;$i<$max;$i++){
            $pid=$_SESSION[[/COLOR]cart[COLOR= #DD0000]][$i][[/COLOR]productid[COLOR= #DD0000]];
            $q=$_SESSION[[/COLOR]cart[COLOR= #DD0000]][$i][[/COLOR]qty[COLOR= #DD0000]];
            $price=get_price($pid);
            $result = mysql_query("insert into order_detail values ($orderid,$pid,$q,$price)");
                      mysql_real_escape_string($result);
}}}else{
?>
    </p>
    <form name="form1" method="POST" action="">
  <div align="center">
        <h1 align="center">Afrekenen</h1>
        <table border="0" cellpadding="2px">
            <tr><td>Totaal bedrag:</td><td>&euro; <?php echo get_order_total()?></td></tr>
            <tr><td>* Bedrijf:</td><td><input type="text" name="bedrijf" is="bedrijf" /></td></tr>
            <tr><td>* Voornaam:</td><td><input type="text" name="voornaam" id="voornaam" /></td></tr>
            <tr><td>* Achternaam:</td><td><input type="text" name="achternaam" id="achternaam" /></td></tr>
            <tr><td>* Email:</td><td><input type="text" name="email" id="email" /></td></tr>
            <tr><td>* Adres:</td><td><input type="text" name="adres" id="adres" /></td></tr>
            <tr><td>* Postcode:</td><td><input type="text" name="postcode" id="postcode" /></td></tr>
            <tr><td>* Plaats:</td><td><input type="text" name="plaats" id="plaats" /></td></tr>
            <tr><td>* Land:</td><td><input type="text" name="land" id="land" /></td></tr>
            <tr><td>** Telefoonnummer:</td><td><input type="text" name="tel" id="tel" /></td></tr>
            <tr><td>** Mobiele nummer:</td><td><input type="text" name="mob" id="mob"/></td></tr>
            <tr><td>* Kamer van Koophandel:</td><td><input type="text" name="kvk" id="kvk" /></td></tr>
            <tr><td>* BTW-nummer:</td><td><input type="text" name="btw" id="btw" /></td></tr>
            <tr><td>&nbsp;</td><td><input type="submit" value="Bestel" /></td></tr>
        </table>
* Deze zijn verplicht in te vullen.<br />
** U kunt kiezen of u een telefoonnummer, mobiele nummer of allebei invult.
    </div>
</form>
<?php
}
?></div>
        
            </div>
        <div id="rechts">
            <div class="titel">Winkelwagen</div>
<div class="content">
<?php
            if(is_array($_SESSION[[/COLOR]cart[COLOR= #DD0000]])){
                echo [/COLOR]    [COLOR= #007700]<[/COLOR]tr bgcolor[COLOR= #007700]=[/COLOR][COLOR= #DD0000]"#FFFFFF"[/COLOR] style[COLOR= #007700]=[/COLOR][COLOR= #DD0000]"font-weight:bold"[/COLOR][COLOR= #007700]><[/COLOR]/tr[COLOR= #007700]>[/COLOR][COLOR= #DD0000];
$max=count($_SESSION[[/COLOR]cart[COLOR= #DD0000]]);
                for($i=0;$i<$max;$i++){
                    $pid=$_SESSION[[/COLOR]cart[COLOR= #DD0000]][$i][[/COLOR]productid[COLOR= #DD0000]];
                    $q=$_SESSION[[/COLOR]cart[COLOR= #DD0000]][$i][[/COLOR]qty[COLOR= #DD0000]];
                    $pname=get_product_name($pid);
                    if($q==0) continue;
?>

<table><tr><td width="25"><?php echo $q?>x</td><td width="135"><?php echo $pname?></td><td width="40">&euro; <?php echo get_price($pid)*$q?></td><td width="15"><a href="javascript:del(<?php echo $pid?>)">Del</a></td></tr></table>
            <?php                    
                }
            ?>
<b>Totaal bedrag: &euro; <?php echo get_order_total()?></b><br /><input type="button" value="Inhoud" onclick="window.location=[/COLOR]shoppingcart[COLOR= #DD0000]"><input type="button" value="Bestel" onclick="window.location=[/COLOR]billing[COLOR= #DD0000]"></td></tr>
        <?php
            }
            else{
                echo "U heeft op dit moment geen producten in uw winkelwagen staan.";
            }
        ?>

</div>
                <div class="titel">Menu</div><br />
                <div class="content">
                
                    <div class="menu" onclick="openmenu([/COLOR]inhoud1[COLOR= #DD0000])"><strong>Home</strong></div>
                    <div id="inhoud1" style="display: none;"> <a href="index">Homepage</a><br /></div>
                    
                    <div class="menu" onclick="openmenu([/COLOR]inhoud2[COLOR= #DD0000])"><strong>About</strong></div>
                    <div id="inhoud2" style="display: none;"> <a href="aboutus">About us</a><br /></div>
                    
                    <div class="menu" onclick="openmenu([/COLOR]inhoud3[COLOR= #DD0000])"><strong>Vaste mast</strong></div>
                    <div id="inhoud3" style="display: none;"> <a href="shop_vast">Vaste cameramasten</a><br /></div>
                    
                    <div class="menu" onclick="openmenu([/COLOR]inhoud4[COLOR= #DD0000])"><strong>Kantelbare mast</strong></div>
                    <div id="inhoud4" style="display: none;"> <a href="shop_kantel">Kantelbare cameramasten</a><br /></div>
                    
                    <div class="menu" onclick="openmenu([/COLOR]inhoud5[COLOR= #007700])[/COLOR][COLOR= #DD0000]"><strong>Contact</strong></div>
                    <div id="[/COLOR]inhoud5[COLOR= #DD0000]" style="[/COLOR]display[COLOR= #007700]:[/COLOR] none[COLOR= #007700];[/COLOR][COLOR= #DD0000]"> <a href="[/COLOR]contact[COLOR= #DD0000]">Contact</a><br /></div>
                                
                </div>
<!--            
                <div class="[/COLOR]titel[COLOR= #DD0000]">Zoeken op de site</div>
                <div style="[/COLOR]margin[COLOR= #007700]-[/COLOR]top[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]59[/COLOR]px[COLOR= #007700];[/COLOR] margin[COLOR= #007700]-[/COLOR]bottom[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]15[/COLOR]px[COLOR= #007700];[/COLOR][COLOR= #DD0000]"><input type="[/COLOR]text[COLOR= #DD0000]" id="[/COLOR]zoeken[COLOR= #DD0000]" /><br /><input type="[/COLOR]submit[COLOR= #DD0000]" value="[/COLOR]Start zoeken[COLOR= #DD0000]" style="[/COLOR]margin[COLOR= #007700]-[/COLOR]left[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]100[/COLOR]px[COLOR= #007700];[/COLOR][COLOR= #DD0000]" /></div>
-->
            <div class="[/COLOR]titel[COLOR= #DD0000]">Nieuws</div>
                <div style="[/COLOR]margin[COLOR= #007700]-[/COLOR]top[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]59[/COLOR]px[COLOR= #007700];[/COLOR] margin[COLOR= #007700]-[/COLOR]bottom[COLOR= #007700]:[/COLOR] [COLOR= #0000BB]15[/COLOR]px[COLOR= #007700];[/COLOR][COLOR= #DD0000]">Testje ofzo</div>
            </div>
</div>

        <div id="[/COLOR]footer[COLOR= #DD0000]">&copy;2012 Cameramast.com - Alle rechten voorbehouden - <a href="[/COLOR]contact"[COLOR= #007700]>[/COLOR]Contact[COLOR= #007700]<[/COLOR]/a[COLOR= #007700]><[/COLOR]/div[COLOR= #007700]>
    
    <[/COLOR]/div[COLOR= #007700]>

<[/COLOR]/body[COLOR= #007700]>
<[/COLOR]/html[COLOR= #007700]>[/COLOR]
Zo danemo?

toevoeging op 5 juli 2012, 00:24:36:
regel 95 moet trouwens yummie
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren