Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

passing on variables - help


Recommended Posts

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">


<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"




<td align="justify">

<form id="formTShops" name="formTShops" method="post"



<input name=shop_id type=hidden


<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"


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


<input type="submit" id="btnProtect" name="btnProtect"

value="Anmeldung zur Geld-zurück-Garantie">








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.



Link to comment
Share on other sites

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


This topic is now archived and is closed to further replies.

  • Create New...