home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Programming Languages Suite
/
ProgLangD.iso
/
VCAFE.3.0A
/
Sample.bin
/
PHVerifyInfo.java
< prev
next >
Wrap
Text File
|
1998-09-13
|
2KB
|
76 lines
package symantec.sourcebook.servlet;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
public class PHVerifyInfo extends PageHandler
{
private final static String PAGENAME = PAGEBASE + "verifyinfo.html";
public PHVerifyInfo()
{
}
public String pageName()
{
return PAGENAME;
}
protected void customize(Object pageDataObject) throws IOException
{
PageData pageData = (PageData) pageDataObject;
Transaction t = pageData.transaction;
// Record transaction information
t.selectId();
t.record();
String orderInformation = t.name + "<br>" +
t.company + "<br>" +
t.email + "<br>" +
t.address + "<br>" +
t.city + " " + t.state + " " + t.zip + "<br>" +
t.country + " " + t.phone +"<br>";
String fieldText = "<input type=\"hidden\" name=\"orderId\" value=\""+ t.orderID +"\"> ";
fieldText += orderInformation + "<br> <br>";
if(t.chargeTax)
{
fieldText += "Product Price: "+t.price+"<br>";
fieldText += "California Tax: "+t.tax+"<br> <br>";
fieldText += "Total Price: "+t.total+"<br>";
}
else
{
fieldText += "Total Price: "+t.total+"<br>";
}
fieldText += "<input type=\"hidden\" name=\"ccTotal\" value=\""+t.total+"\">";
fieldText += "<input type=\"hidden\" name=\"ccName\" value=\""+t.name+"\">";
insert("fieldPosition",fieldText);
}
// this form is never submitted to our web server (and therefore no validation)
// the form is validated by the credit card processor
public Object validate(ServletConfig config,HttpServletRequest request,HttpServletResponse response)
{
return null;
}
}