Location: PHPKode > scripts > sellaOTP > sellaotp/example.php
/* sella_OTP.class                                                      */
/* ========                                                             */
/*                                                                      */
/* Copyright (c) 2002 by Angelo Gelmi                                   */
/* http://www.web3king.com/sellaOTP 									*/
/* hide@address.com								                        */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<body bgcolor="#FFFFFF" text="#000000">
<td height="498"> 
    <table border="0" width="640" cellspacing="0" cellpadding="0" class="corponove">
        <td valign="top"> <table border="0" width="97%" class="corponove" cellspacing="1" bgcolor="#000000">
            <tr bgcolor="#CCCCCC"> 
              <th bgcolor="#FF9900" class="corpootto">Shipping</th>
              <th bgcolor="#FF9900" class="corpootto">Shipping Amount</th>
              <th bgcolor="#FF9900" class="corpootto">Payment Method</th>
            <tr bgcolor="#E6F7FF"> 
              <td height="18" bgcolor="#ffffff"> <div align="center" class="corpootto"> 
              <td align="right" height="18" bgcolor="#ffffff"> <div align="center" class="corpootto"> 
              <td align="center" height="18" bgcolor="#ffffff"> <div align="center" class="corpootto"> 
          <br> <br> </td>
        <td width="150" rowspan="2" valign="top"> <table border="0" width="100%" class="corponove" cellspacing="1" bgcolor="#000000">
              <th width="100%" bgcolor="#FF9900">Tot. Order</th>
              <td width="100%" bgcolor="#e0e0e0" align="right"> <div align="center"><b> 
      				print number_format($totale_carrello , "2", ",", ".");
                  </b> </div></td>
        <td valign="top"><form action="<? echo $PHP_SELF; ?>" method="post" name="form" id="form">
				require "sella_OTP.class.php";
				$amount=ereg_replace( ",", ".", $totale_carrello ); 
				$transazione = new sella_OTP();
				$transazione->SetStore("file");    // option file or sql
				$transazione->LING            = 1; //optional if used you have to configure Sella Back END
				$transazione->PAY1_AMOUNT     = $amount ;
				$transazione->PAY1_IDLANGUAGE = 1;
				$transazione->PAY1_UICCODE    = "242";
				$transazione->PAY1_SHOPTRANSACTIONID	="123456789";// id session Your variable. MUST be different each time
				$ret=$transazione->make_query("1234567"); //Merchant ID
				if (!empty($transazione->error_log))
					print "Error: $transazione->error_log";
					$transazione->show_form("get"); 	//options get or post
Return current item: sellaOTP