|
|||
|
Guten Morgen,
ich brauche für mein Partnerprogramm die Netto-VK-Preise. Ich habe folgende Abfrage in der checkout_success.php eingebunden: // get order id $sql = "select orders_id from ".TABLE_ORDERS." where customers_id='".$_SESSION['customer_id']."' order by orders_id desc limit 1"; $pap_orders_query = xtc_db_query($sql); $pap_orders = xtc_db_fetch_array($pap_orders_query); $pap_order_id = $pap_orders['orders_id']; // get total amount of order $sql = "select products_price, products_tax, products_quantity from ".TABLE_ORDERS_PRODUCTS." where orders_id='".(int)$pap_order_id."'"; $pap_orders_total_query = xtc_db_query($sql); $pap_orders_total = xtc_db_fetch_array($pap_orders_total_query); $affiliate_total = 0; for ($i=0, $n=sizeof($pap_orders_total); $i<$n; $i++) { $affiliate_total += (($pap_orders_total[$i]['products_price'] * 100) / (100 + $pap_orders_total[$i]['products_tax'])) * $pap_orders_total[$i]['products_quantity']; } Das Problem ist die for-Schleife was muss ich bei sizeof eintragen, kann mir jemand helfen. Danke Michael |
![]() |
| Lesezeichen |
| Stichworte |
| array, checkoutsuccess |
| Themen-Optionen | |
| Ansicht | |
|
|
Ähnliche Themen
|
||||
| Thema | Autor | Forum | Antworten | Letzter Beitrag |
| "Wer ist Online"Wieso? Fehler: Variable passed to each() is not an array or object... | Topis | Admininterface | 7 | 08.07.2011 11:55 |