%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%@ taglib uri="http://www.osoa.org/sca/sca_jsp.tld" prefix="sca"%>
<% String c = request.getParameter("charge"); if (c != null) { ObjectFactory objectFactory = new ObjectFactory(); CreditCardDetailsType ccDetails = objectFactory.createCreditCardDetailsType(); ccDetails.setCreditCardType(CreditCardTypeType.fromValue(request.getParameter("type"))); ccDetails.setCreditCardNumber(request.getParameter("cardNumber")); ccDetails.setCVV2("123"); ccDetails.setExpMonth(12); ccDetails.setExpYear(2011); PayerType ccOwner = objectFactory.createPayerType(); ccOwner.setName(request.getParameter("cardHolder")); ccDetails.setCardOwner(ccOwner); float amount = Float.parseFloat(request.getParameter("amount")); %> <%=service.authorize(ccDetails, amount)%> <% } %>