BareMetal.com

Baremetal
My Account
Domain Registration Management Services
Web Services
Rates and Specs
Bulk Rates
CGI Library
FAQ
Order Form
Tech Support
Billing Info
Company Info
Charities
Legal Info
Employment
Privacy Statement

BM


Web Services

Templates;

Return CGI Library
Return Form Handling

One of the biggest strengths of this gadget is the formatting flexibility you can get by using templates.

Templates are simply text files into which you put "curly braces" and the field name you want to show. (The CGI environment variables, and GMT_TIME and LOCAL_TIME are also available.)

Two templates can be specified: a variable called REPLY can specify a template to be used for the "response page", and another called TEMPLATE can specify one to be used for the e-mail message.

As an example: if you have an order form with the fields "realname" and "phonenum" then you might want to have a response screen that would say something like:

Thank You for your order Tom Brown.

One of our representatives will soon be calling you at 555-1212 to confirm payment details.

You could accomplish it with the following template:

<p><b>Thank You</b> for your order <b>{realname}</b>. </p>

<p> One of our representatives will soon be calling you at <b>{phonenum}</b> to confirm payment details. </p>

The same type of template formatting can be used to control the display of the response on the browser's screen, the formatting of an e-mail response message, or even the formatting of the data as saved in a disk file.

Specifying templates... All template specifications are the same as the URL to the template file would be. (Note that some file types are considered security sensitive and the gadget will refuse to use them.)

e.g. TEMPLATE=/gadgets/mail2/demo.tpl specifies the same file you would see if you went to http://baremetal.com/gadgets/mail2/demo.tpl.



 
Home Page    Domain Registration Services    Web Services    Technical Support
About Baremetal    Privacy Statement    Billing Info    Charities
My Account    Legal Info    Search BareMetal

Copyright © 1996-2012, BareMetal.com Inc.
Last updated: Thursday, 28-May-2015 16:14:54 PDT
Last Accessed from: ec2-18-218-250-241.us-east-2.compute.amazonaws.com
Questions and comments to support@baremetal.com