Isomedia Logo Get Connected. Stay Connected. Be Connected. Isomeda Image
Internet Services Contact Us
Home Internet Services
DSL Services
DSL FAQ
DSL Prequal
Dial-up Access
Domain Registration
Dedicated Dial-up
ISDN
Web Services
Business Internet Services
DSL Services
DSL FAQ
DSL Prequal
Dedicated Access
Colocation & Dedicated Servers
Virtual Private Servers
How it Works
Features
Information Request
Service Manager
Service Administrator
Web Services
Domain Registration
Business Solutions
My Account
Account Information
Webmail
Search Engines
Classifieds
Link to ISOMEDIA
Refer Someone
Internet Support
Support Resources
Support Request
Resellers & Referrals
Request Form
Pay Bill Online
Rebates
Contact Us

Live Chat

Live Chat

Network Status ISOMEDIA Network RSS


Internet Icon

CGI Scripts

Form Mail Script
Image Map Script
Website Counter Script

Form Mail Script

Overview

Formmailer.cgi is a perl script on home.isomedia.com, another computer at ISOMEDIA.COM capable of activities on the World Wide Web.

If you make an HTML page with forms in it, and you name formmailer.cgi as the "action", when someone visits your form HTML page, puts data into the form, and presses the submit button, formmailer.cgi will make an email and send it to someone. After it sends the email, formmailer.cgi sends the user's web browser to another page, so they can be thanked for filling out the form, or so they can go on with browsing your site. Who formmailer.cgi sends the email to, what the subject of the email is, who the sender is listed as, and where the user's browser gets sent after the email is sent are all controlled by your HTML page. All other information from the HTML form gets put into the body of the message and sent.

How to use formmailer.cgi

Using formmailer.cgi is easy. Just do this:

1. Make your html file with a form in it, and make the <form> tag look like this:

<form action="http://home.isomedia.com/cgi-bin/isohome/formmailer.cgi" method=post>

2. Include the following hidden <input> tags: "sender", "recipient", "subject, and "backpage" (NOTE: "backpage" must be a fully qualified absolute URL, you should be able to put it in a web browsers address bar AS IS and view that page, relative links will not work). For example, you could just copy the following into your form:

<input type=hidden name="sender" value="My HTML order Form">
<input type=hidden name="recipient" value="myemailaddress@isomedia.com">
<input type=hidden name="subject" value="Flowers Order">
<input type=hidden name="backpage" value="http://www.someplace.com/mydir/after_you_signed.html">

3. Write the rest of your form.
Any regular <input>, hidden <input>, radio <input>, <textarea> or <select> tags you put in will be put into the body of the message, one input per line, For instance, if you had in your form the following:

<input name="User's Name" size="32">

and the user typed in "Hal 9000" on your web page and pressed the "Submit" button, the email sent to whoever was specified in the "recipient" <input> tag would look like this:

(email header, with form, to, sent by and time, etc...)
User's Name: Hal 9000

And you can put as many <input> tags in your document as you want. As far as we've seen, formailer.cgi will send them all to you.

4. After the email is sent, the user's browser is automatically told to go the web page specified by the <input> tag "backpage". Actually, it doesn't have to be a web page, it could be an ftp site or a gopher site or even a telnet command. Whatever you type in, make sure it has the fully qualified URL(Universal Resource Locater), including the access method. (for instance, "http://www.isomedia.com" if you want to send the user to the ISOMEDIA.COM home page on the web after they signed it.)

About formmailer.cgi

Formmailer.cgi was written by Eugene Goodrich during his employment at ISOMEDIA.COM for customer use. It is written for perl5, and uses "CGI.pm", an excellent perl5 CGI tool. CGI.pm can be located at
http://www-genome.wi.mit.edu/ftp/pub/software/www/cgi_docs.html.

Image Map Script

Use of ISMAP by an HTTP Server Script

The ISMAP attribute for the IMG element lets you to turn an image into a graphically active element. This means that you can select regions of the image by clicking the mouse on them, and that clicking on different regions will cause the server to take different actions.

ISOMEDIA supports the CERN based HTTP ISMAP style of Image Maps and understands that the file refrenced by .map will contain the information regarding the pictures coordinates.

Conceptually this is done by creating, on the HTTP server, a map between certain regions and the corresponding action. These regions can be specified as boxes, circles, or inscribed polygons.

Then, when you click on the image, the coordinates of your click are sent down to a program on the server that looks in this database for the action associated with those coordinates.

The program then returns a message back to the browser that tells the browser which document it should access. This is known as a server redirect message, and is one of the standard messages of the HTTP protocol.

HTML Code for Active Image

The following is an example, where the GIF file bozo.gif is declared active:

<A HREF="http://www.isomedia.com/homes/username/maps/bozo.map"> <IMG SRC=bozo.gif ISMAP> </A>

The ISMAP attribute declares the image to be active - when you click the mouse over the image the browser sends to the server the pixel coordinates of the mouse, with respect to the image origin.

Imagemap

The data must be processed by a program on the server. This is accomplished by creating a hypertext link from the image to the cgi program referenced by the .map extension. This program is designed to process the ISMAP data returned by the browser, and in turn will activate the correct URL by comparing the mouse coordinates with the information in the imagemap's map file.

The imagemap script must also be told which image database to use (each image will have its own map database). This is done by accessing /homes/username/maps/bozo.map and the name of the imagemap database appropriate to the image. Imagemap takes this extra information (known as "extra path" information) and uses it to access the indicated database file.

Imagemap Map Configuration File

The database files map regions of the image to particular URLs. Again, lines beginning with # are comments, Every other non-blank line consists of the following:

method URL x1,y1 X2,y2 ... xn,yn

The meaning and required number of coordinates (x1,y1) depends on the medthod. The different methods are:

circle
When using 'circle' as the appropriate geometric form of measurement, two pairs of coordinates are required:
the center and edgepoint coordinates are needed.
rect
When using 'rect' as the appropriate geometric form of measurement, two pairs of coordinates are required:
The upper-most left and the lower-right coordinate is needed.
poly
When using a polygon, with the most of 100 vertices, each coordinate pair would be a vertex.
The URL is either a relative or absolute URL. Recall that a relative URL is a URL to the server being currently accessed, but without the http://hostname part, and that in the absence of a leading slash the document is searched for relative to the directory containing the current document.

Coordinates in Map Files
So how do you find the coordinates for these domains? They are referenced by the pixel coordinates. The origin for the coordinate is the UPPER LEFT-HAND image corner. How do you get these coordinates? The image program xv does this quite easily, as do a number of commercial packages.

Recall that the IMG element can only display GIF and X-bitmap images inlined. Therefore you can only use those images when referencing your ISMAP's.

The
NCSA ISMAP documentation contains further descriptions of the ISMAP facility, along with examples of an active image and of a map configuration file.

Mapedit, written by Thomas Boutell, is a great program for finding the coordinates in an image. For the most recent version of this utility, go to: http://www.boutell.com/mapedit

Website Counter Script

Overview

Here is how to implement the feature:

When counter.cgi runs, it takes the total for your page from the database, and builds a ".gif" file from ten small graphic files, one for each digit from "0" to "9". You can select from a variety of styles for the counter.

The program then returns it's output as a ".gif" file, which the WWW Server places right on your page for your users to see.

Here's how to add the code to your website:

1. Add a link to an "img" resource just like you were going to link to a Graphic.

2. In the link, set the "src" to the following code:

<img src="http://utility.isomedia.com/cgi-bin/isohome/counter.cgi?">

3. After the "http://utility.isomedia.com/cgi-bin/isohome/counter.cgi?", you can add minwidth=X& where X is the minimum number of digits you want in the counter. You can leave off that part if you want the counter program to decide how many digits to use (for instance, 4 digits for 1000 through 9999), or you can put "minwidth=X" to make sure that the counter never has less that X digits.
(It'll put zeros for the extra digits it needs.)

5. The last thing you specify is the Style. After the link, add style=X where X is a letter between "A" and "O" or a number between "1" and "15". These are the available styles:

Counter Style "1" Counter Style "A"
Counter Style "2" Counter Style "B"
Counter Style "3" Counter Style "C"
Counter Style "4" Counter Style "D"
Counter Style "5" Counter Style "E"
Counter Style "6" Counter Style "F"
Counter Style "7" Counter Style "G"
Counter Style "8" Counter Style "H"
Counter Style "9" Counter Style "I"
Counter Style "10" Counter Style "J"
Counter Style "11" Counter Style "K"
Counter Style "12" Counter Style "L"
Counter Style "13" Counter Style "M"
Counter Style "14" Counter Style "N"
Counter Style "15" Counter Style "O"


The above examples are working counters, as well as the one below. Cut and paste the example below, and enter your own personal name for your counter.

<img src="http://utility.isomedia.com/cgi-bin/isohome/counter.cgi? link=yourlinknamehere&style=a">>

(the above example is one continuous line)

For support or questions on the Web Counter, contact
support@isomedia.com
   > Home -- > About Us -- > Press -- > Terms and Conditions -- > Privacy Policy -- > Jobs   ©1995-2008 ISOMEDIA, INC. All Rights Reserved