include("dane.php"); ?>
if (!empty($HTTP_POST_VARS["ostatecznie"]))
{ // tu wchodzi po ostatecznym zatwierdzeniu
podsumowanie("1",
$HTTP_POST_VARS['name'],
$HTTP_POST_VARS["company"],
$HTTP_POST_VARS["street_address"],
$HTTP_POST_VARS["city"],
$HTTP_POST_VARS["country"],
$HTTP_POST_VARS["email"],
$HTTP_POST_VARS["no_of_books"],
$HTTP_POST_VARS["cost_of_book"],
$HTTP_POST_VARS["cost_of_delivery"]);
}
else if(!empty($HTTP_POST_VARS["powrot"]))
{
// tu wchodzi po kliknięciu 'Powrót do poprawy danych'
print_form("",$HTTP_POST_VARS['name'],
$HTTP_POST_VARS["company"],
$HTTP_POST_VARS["street_address"],
$HTTP_POST_VARS["city"],
$HTTP_POST_VARS["country"],
$HTTP_POST_VARS["email"],
$HTTP_POST_VARS["no_of_books"],
$HTTP_POST_VARS["cost_of_book"],
$HTTP_POST_VARS["cost_of_delivery"]);
}
else if(empty($HTTP_POST_VARS["dalej"]))
{
// tu wchodzi przy pierwszym wyświetleniu strony
print_form("","","", "","","", "","", "","");
}
else
{
// tu wchodzi po kliknięciu 'Zamawiam' na pierwszej stronie
if (($error=sprawdz_dane2(
$HTTP_POST_VARS["name"],
$HTTP_POST_VARS["company"],
$HTTP_POST_VARS["street_address"],
$HTTP_POST_VARS["city"],
$HTTP_POST_VARS["country"],
$HTTP_POST_VARS["email"],
$HTTP_POST_VARS["no_of_books"],
$HTTP_POST_VARS["cost_of_book"],
$HTTP_POST_VARS["cost_of_delivery"]))!='')
{
// tu wchodzi, gdy niepusty $error
print_form($error,
$HTTP_POST_VARS["name"],
$HTTP_POST_VARS["company"],
$HTTP_POST_VARS["street_address"],
$HTTP_POST_VARS["city"],
$HTTP_POST_VARS["country"],
$HTTP_POST_VARS["email"],
$HTTP_POST_VARS["no_of_books"],
$HTTP_POST_VARS["cost_of_book"],
$HTTP_POST_VARS["cost_of_delivery"]);
}
else
{
// tu wchodzi, gdy nie ma błędów po kliknięciu 'Zamawiam'
podsumowanie("0",
$HTTP_POST_VARS['name'],
$HTTP_POST_VARS['company'],
$HTTP_POST_VARS["street_address"],
$HTTP_POST_VARS["city"],
$HTTP_POST_VARS["country"],
$HTTP_POST_VARS["email"],
$HTTP_POST_VARS["no_of_books"],
$HTTP_POST_VARS["cost_of_book"],
$HTTP_POST_VARS["cost_of_delivery"]);
}
}
function print_form($error,$name,$company,$street,$city,$country,$email,
$no_of_books,$cost_of_book,$cost_of_delivery)
{
global $cena_produktu_1;
// jeżeli serwer dorzuca slashe, to usunšć je
if (get_magic_quotes_gpc ())
{
$name = stripslashes ($name);
$company = stripslashes ($company);
$street = stripslashes ($street);
$city = stripslashes ($city);
$country = stripslashes ($country);
$e_mail = stripslashes ($e_mail);
$no_of_books = stripslashes ($no_of_books);
$cost_of_book = stripslashes ($cena_produktu_1);
$cost_of_delivery = stripslashes ($cost_of_delivery);
}
$name = htmlspecialchars ($name, ENT_QUOTES);
$company = htmlspecialchars ($company, ENT_QUOTES);
$street = htmlspecialchars ($street, ENT_QUOTES);
$city = htmlspecialchars ($city, ENT_QUOTES);
$country = htmlspecialchars ($country, ENT_QUOTES);
$e_mail = htmlspecialchars ($e_mail, ENT_QUOTES);
$no_of_books = htmlspecialchars ($no_of_books, ENT_QUOTES);
$cost_of_book = htmlspecialchars ($cena_produktu_1, ENT_QUOTES);
$cost_of_delivery = htmlspecialchars ($cost_of_delivery, ENT_QUOTES);
if(!empty($error))
print('
'.$error.'
');
if( $ilosc1=="") $ilosc1=1;
//$link = 'Do strony głównej' ;
$link = '' ;
print('
Delivery to | Single or double book delivery cost (economy) EUR | Single or double book delivery cost (priority) EUR |
---|---|---|
Poland | 2.0 | 2.5 |
Europe and Middle East | 12.0 | 17.5 |
North America | 12.50 | 22.80 |
Latin America | 12.25 | 28.20 |
Africa | 12.50 | 22.80 |
Asia | 12.50 | 22.80 |
Australia and Oceania | 12.25 | 43.50 |
Please check your data and authorize your order.
'); } //if($delivery=="1" && $tryb=="1") { print('
Seller: Uslugi Komputerowe Teresa Niederlinska ul. Pszczynska 118A/28 PL 44-100 Gliwice, POLAND tel/fax: 032 232 26 43 mail: teresa@uktn.com NIP: 631-107-25-36 Bank Account: PL 85 1050 1298 1000 0090 6013 2967 SWIFT code: INGBPLPW Local bank office: ING BANK O/GLIWICE POLAND |
Buyer: '.$name.' '.$company.' '.$street.' '.$city.' '.$country.' '.$email.' |
|||||||||
Item | PKWiU | Units | Unit price | Number of books |
Price netto |
VAT | Value of VAT |
Price brutto |
||
Book A. Niederlinski "A Quick and Gentle Guide to Constraint Logic Programming via ECLiPSe" | 22.11 | item | '.$cena_produktu_1.' EUR | '.$no_of_books.' | '.$total1.' EUR | 0% | 0 | '.$total1.' EUR | ||
Cost of delivery: | '.$cost_of_delivery.'EUR | |||||||||
Total: | '.$total.'EUR |
'.$total.' EUR to be paid by transfer to Bank Account
The book (books) and invoice will be send after bank transfer is accomplished
'); } /* if ($delivery=="2") { $total=$total1+$koszt_pobrania; print('Do zapłaty przy odbiorze: '.$total.' zł. '); } */ if ($tryb=="0") { print('
Order is accepted for realization after clicking "Order authorization". |
' ); //Faktura VAT $tresc='
Faktura VAT nr
Oryginał / Kopia
Data wystawienia faktury:
Data sprzedaży:
Zapłacono: '.$total1.' zł słownie: '.$slownie.' EUR |
|
|
osoba uprawniona do wystawienia faktury vat |