uShopPrintFormCGI.class
The uShopPrintFormCGI applet is similar to the order form
applets except that it does not ask for any payment information and
instead of processing the order, it creates a CGI-generated print
page to allow the customer to print out the order and mail or fax
it to the store. Options let you customize the form's titles,
instructions, and footnoot. To use this applet, you must have
configured the ushop_cgiscript1p3.pl in your cgi directory on your
secure server.
See also ushop_cgiscript1p3.pl.
In addition, this applet also allows you to setup shipping, tax, and payment
options as described below.
Parameters
- scriptpath - The full path to the ushop_cgiscript1p3_de.pl on your server. Example:
"http://www.mystore.com/cgi-bin/ushop_cgiscript1p3_de.pl".
- taxrate - The default tax rate. Specify this as a value 0.00 through 1.00
(ie. "0.06" or "0.07") - DO NOT use a percent (%) sign.
- taxtable - This parameter allows you to override the default tax rate for
customers from specified states. That is, in this parameter you
can specify special tax rates for specific states. The format
should be "<state>=<taxrate>,<state>=<taxrate>,...". You can
specify as many states as you want. Example: "FL=0.06,FLORIDA=0.06,
TX=0.07,TEXAS=0.07" would charge customers from Florida and Texas
tax rates of 6% and 7%, respectively.
- shipping - This parameter allows you to specify what shipping methods are
available and how to calculate the shipping for each method. See
the page on shipping setup
for additional information on setting up Shipping.
- handling - This parameter allows you to specify a default handling fee that
will be added to all orders. Example: "$2.00" would charge
customers an additional $2.00 per order.
- handlingtable - This parameter allows you to override the default handling
rate for customers from specified countries. That is, in this
parameter you can specify special handling fees for specific
countries. The format should be "<country>=<handlingfee>,
<country>=<handlingfee>,...". You can specify as many countries
as you want. Example: "USA=$1.00,United States=$1.00,U.S.A.=$1.00,
US=$1.00,CANADA=$1.00" would charge customers who live in the US
or Canada a $1.00 handling fee.
- label - The label that will appear on the print button. This can be any
text you like, such as "Print Order" or "Fax Order".
- title - The title that will appear on the print page. Examples: "Print Order"
or "Fax Order".
- instructions - The instructions that will appear on the print page. This can say
whatever you like such as "(From your browser select print, fill
out the form, then fax it to us at 1-800-555-5555)".
- section1 - The text that will appear over the first section. Typically this will
indicate what to enter into this section of the form. Such as "Name,
Address, Telephone".
- section2 - The text that will appear over the second section. Typically this will
indicate what to enter into this section of the form. Such as
"Shipping Information".
- section3 - The text that will appear over the third section. Typically this will
indicate what to enter into this section of the form. Such as
"Payment Information - We accept Visa, Master Card and COD".
- footnoot - The text that will appear at the bottom of the form. You can specify
any message here such as "*Appropriate sales tax will be added.".
- return_url - This parameter lets you specify a URL to be used as a "BACK" link
on the order receipt page. That is, if you specify a full URL here,
uShop will add a "BACK" link on the bottom of the order receipt page
to link to the specified URL. Example: "http://www.uburst.com".
- background - The background color of the applet. You can specify an
RGB value separated by commas ("integer,integer,integer" where
each integer is a value between 0 and 255) or specify one of
the predefined colors: white, black, lightGray, gray, darkGray,
red, green, blue, yellow, magenta, cyan, pink, and orange. The
default value is "white".
Note: Optional parameters are in italics
Example
This print form example has been setup:
- To send the order information to the ushop_cgiscript located in our cgi-bin directory.
- To charge no tax, except for customers from Florida - who are charged 6% sales tax.
- To allow 3 shipping methods: UPS based on subtotal, FED EX based on total weight, and
Over Night at a flat rate of $50.00.
- To charge no handling fees for customers in the US and a $5.00 handling fee for
customers outside the US.
- To add the message "Thank you for shopping with us." to all order receipts.
- To add a BACK link to "http://www.uburst.com" on the order receipt page.
- And to have a light gray background color.
<APPLET CODE = "uShopPrintFormCGI.class" WIDTH=450 HEIGHT=550>
<PARAM NAME=scriptpath VALUE="http://www.uburst.com/cgi-bin/ushop_cgiscript1p3.pl">
<PARAM NAME=taxrate VALUE="0.00">
<PARAM NAME=taxtable VALUE="FL=0.06,FLORIDA=0.06">
<PARAM NAME=shipping VALUE="UPS,BY_SUBTOTAL,20=$5.00,35=$7.00,50=$10.00,$15.00;
FED EX,BY_WEIGHT,10=$5.00,20=$10.00,$25.00;
Over Night,FLAT_RATE,$50.00">
<PARAM NAME=handling VALUE="$5.00">
<PARAM NAME=handlingtable VALUE="US=$0.00,USA=$0.00,U.S.=$0.00,U.S.A.=$0.00,United States=$0.00">
<PARAM NAME=label VALUE="Print Order">
<PARAM NAME=title VALUE="Order Form">
<PARAM NAME=instructions VALUE="(From your browser select print, fill out the form, then fax it to us at 1-800-555-555)">
<PARAM NAME=section1 VALUE="Personal Information">
<PARAM NAME=section2 VALUE="Shipping Information">
<PARAM NAME=section3 VALUE="Payment Information">
<PARAM NAME=footnote VALUE="*Make checks payable to Microburst Technologies, Inc.">
<PARAM NAME=return_url VALUE="http://www.uburst.com">
<PARAM NAME=background VALUE="lightGray">
</APPLET>