huwcole Posted December 12, 2002 Share Posted December 12, 2002 hi guys i signed up with "a trusted shop scheme" and they asked to put the following code into the checkout_success.php which offers customers a money back guarantee: <table width=400 border="0" cellspacing="0" cellpadding="4"> <tr> <td width="90"> <form name="formSiegel" method="post" action="https://www.trustedshops.de/tshops/siegel.php3" target="_blank"> <input type="image" border="0" src="./img/siegel.gif" alt="Trusted Shops Gütesiegel - Bitte hier klicken."> <input name="shop_id" type="hidden" value="XDFGDFGDFGDFGB189C743396C61791"> </form> </td> <td align="justify"> <form id="formTShops" name="formTShops" method="post" action="https://www.trustedshops.de/tshops/protect.php3" target="_blank"> <input name=shop_id type=hidden value="XERTERTERT30C449FB189C743396C61791"> <input name="title" type=hidden value="[value title]"> <input name="email" type="hidden" value="[value email]"> <input name="first_name" type=hidden value="[value fname]"> <input name="last_name" type=hidden value="[value lname]"> <input name="street" type=hidden value="[value street]"> <input name="zip" type=hidden value="[value zip]"> <input name="city" type=hidden value="[value city]"> <input name="country" type=hidden value="[value country]"> <input name="phone" type=hidden value="[value phone]"> <input name="fax" type=hidden value="[value fax]"> <input name="delivery" type=hidden value="[value delivery]"> <input name="amount" type=hidden value="[value amount]"> <input name="curr" type=hidden value="[value curr]"> <input name="payment" type=hidden value="[value payment]"> <input name="kdnr" type="hidden" value="[value kdnr]"> <input name="ordernr" type="hidden" value="[value ordernr]"> <font size="2" face="Arial,Helvetica,Geneva,Swiss,SunSans-Regular"color="#000000"> Als Trusted Shops Mitglied bieten wir Ihnen als zusätzlichen Service die Geld-zurück-Garantie der Gerling Versicherungsgruppe an. Wir übernehmen alle Kosten dieser Garantie, Sie müssen sich lediglich anmelden.<br><br> <input type="submit" id="btnProtect" name="btnProtect" value="Anmeldung zur Geld-zurück-Garantie"> </font> </form> </td> </tr> </table> basically what happens is when the customer presses the submit button all their details are transfered to their page. my question now is how can i get the values into the hidden fields. thanks Link to comment Share on other sites More sharing options...
Christian Lescuyer Posted December 13, 2002 Share Posted December 13, 2002 Generally speaking, the method is to print the variables wherever you need in the HTML code. Eg: <input name="first_name" type=hidden value="<?php print $variable; ?>"> But checkout_success.php? Anyway, most variables are not available anymore on this page, the order is sent. You'll have to get the info from the database. Use $_SESSION['customer_id'] to get the customer info and $_SESSION['last_order'] to get the order info. You'll find examples of queries in about all files. Christian Lescuyer Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.