Hi i am trying to integrate Virtual Pos  to my GWT Project.

the bank sent me an example code which uses JSP.
could some one help me how to translate this structure to GWT

here is the example code that bank has given to me ..

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd";>
<%@ page contentType="text/html;charset=UTF-8"%>
<%@page language="java" 
import="java.io.UnsupportedEncodingException,java.security.NoSuchAlgorithmException,
                                
java.util.*,com.gwt.pt.web.server.VPOS_Garanti.PAX.Payment.java3DModeltestler.AeSimpleSHA1"%>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
      
           
    </head>
    <body>
     <%
            String kkno=request.getParameter("kkno");
            
            String  strMode = "TEST";  //gerçek mağazanızda PROD olacak      
            String strApiVersion = "v0.01";
            String strTerminalProvUserID = "PROVAUT";
            String strType="sales";
            String strAmount="100";//    işlem tutarı ne ise o yazılacak
            String strCurrencyCode="949";
            String strInstallmentCount="";//      Taksit sayısını 
göstermektedir. Taksitli işlemlerde sayı girilecek. Peşin işlemlerde boş 
gönderilecek. 
            String strTerminalUserID="ETİCARET"; //         işlemi yapan 
kullanıcı adı, bu kullanıcı adında Türkçe karakter, işaret sembol boşluk 
olmamalı. 
            String strOrderID="014";    //    sipariş numarası her işlemde 
farklı olacak
            String strCustomeripaddress= request.getRemoteAddr(); //       
işlemi yapan müşterinin IP numarası 
            String strcustomeremailaddress= "[email protected]";//        
  işlemi yapan kullanıcının mail adresi
            String strTerminalID="30691297";      ///   test mağazası için 
111995 olacak
            String strTerminalID_ = "030691297";///" & strTerminalID     toplam 
9 diğitli terminal ID olmalı gerçek mağaza işlemlerinde düzenleme yapılmayacak 
ama test mağazasını terminal numarası kısa olduğu için "000" & strTerminalID 
olmalı
            String strTerminalMerchantID="7000679";//  test mağazası için 600218
            String strStoreKey="12345678";       // test mağazası için 12345678 
            String strProvisionPassword="123qweASD";// test mağazası için 
123qweASD
            String 
strSuccessURL="http://127.0.0.1:7101/SanalPOS-BankaWeb-context-root/garantiodeme.jsp";;
            String strErrorURL= 
"http://127.0.0.1:7101/SanalPOS-BankaWeb-context-root/garantiodeme.jsp";;
            String SecurityData= null;
            try {
                SecurityData = AeSimpleSHA1.SHA1(strProvisionPassword+ 
strTerminalID_);
                } catch (UnsupportedEncodingException ex) {
                out.println("Hash işleminde hata");
                }
             String HashData = null;
            try {
               HashData = AeSimpleSHA1.SHA1(strTerminalID + strOrderID + 
strAmount + strSuccessURL + strErrorURL + strType + strInstallmentCount + 
strStoreKey+SecurityData.toUpperCase());
            } catch (UnsupportedEncodingException ex) {
                out.println("Hash işleminde hata");
            }
     %>
      
     <center>
            <form method="post" 
action="https://sanalposprovtest.garanti.com.tr/servlet/gt3dengine";>
                <table>
                    <tr>
                        <td>Kredi Kart Numarası:</td>
                        <td><input type="text" name="cardnumber" size="20" 
value="<%=kkno%>"/>
                    </tr>
                     <tr>
                        <td>Son Kullanma Ayı:</td>
                        <td><input type="text" name="cardexpiredatemonth" 
value=""/></td>
                    </tr>
                    <tr>
                        <td>Son Kullanma Yılı:</td>
                        <td><input type="text" name="cardexpiredateyear" 
value=""/></td>
                    </tr>
                    
                    <tr>
                        <td>Güvenlik Kodu:</td>
                        <td><input type="text" name="cardcvv2" size="4" 
value=""/></td>
                    </tr>
                    
                    
                </table>
                <input id="submit" type="submit" value="İşlemi Gönder" />
                <input type="hidden" name="secure3dsecuritylevel" value="3D" /> 
               
                <input type="hidden" name="mode" value="<%=strMode %>" />
                <input type="hidden" name="apiversion" value="<%=strApiVersion 
%>" />
                <input type="hidden" name="terminalprovuserid" 
value="<%=strTerminalProvUserID %>" />                
                <input type="hidden" name="terminaluserid" 
value="<%=strTerminalUserID %>" />
                <input type="hidden" name="terminalmerchantid" 
value="<%=strTerminalMerchantID %>" />
                <input type="hidden" name="txntype" value="<%=strType %>" />    
            
                <input type="hidden" name="txnamount" value="<%=strAmount %>" />
                <input type="hidden" name="txncurrencycode" 
value="<%=strCurrencyCode %>" />                
                <input type="hidden" name="txninstallmentcount" 
value="<%=strInstallmentCount %>" />             
                <input type="hidden" name="orderid" value="<%=strOrderID %>" /> 
               
                <input type="hidden" name="terminalid" value="<%=strTerminalID 
%>" />
                <input type="hidden" name="successurl" value="<%=strSuccessURL 
%>" />
                <input type="hidden" name="errorurl" value="<%=strErrorURL %>" 
/>
                <input type="hidden" name="customeremailaddress" 
value="<%=strcustomeremailaddress %>" />
                <input type="hidden" name="customeripaddress" 
value="<%=strCustomeripaddress %>" />
                <input type="hidden" name="secure3dhash" 
value="<%=HashData.toUpperCase()%>" />
                      
            
            
            
    </form>
    </center>
    </body>
</html>

Reply via email to