Text Links Ads : Marketing Tips Store : Search Engine Optimization Strategies
WebPosition Gold Pro : Domain Registration Bank : Optilink Software : GoDefy
Mike's Marketing Tools : Mike's Ecommerce Software : Text Links Guide
 
Web HTML-HTML.com
You are here: HTML Codes > Forms > Rollover Submit Image

Rollover Submit Image: Other Settings

By default, all the rollover submit script requires is the sources of the "over" and "out" images and a nickname for the image. The script allows you to set a few other optional settings as well:

<FORM ACTION="../cgi-bin/html/mycgi.pl" NAME="myform">
email: <INPUT NAME="email">
<SCRIPT TYPE="text/javascript">
<!--
var sr = new submitroll("submit.out.gif","submit.over.gif","mysubmit");
sr.alt="OK";
sr.width=60;
sr.height=60;
sr.otheratts="ALIGN=TOP";
sr.write();
//-->
</SCRIPT>
<NOSCRIPT>
<INPUT TYPE=SUBMIT VALUE="Go!">
</NOSCRIPT>
</FORM>

email:
The code here is almost the same as in our previous example. This time we've just added a few lines.

By default the alternate text for the image is Submit Query. In our example above, sr.alt="OK"; sets the alternate text as "OK" to match the text in the image.

sr.width=60; and sr.height=60; set the width and height of the image.

Finally, the script gives an opportunity to add some attributes to the <IMG ...> tag. In this the form looks better if the text field is aligned with the top of the image instead of the bottom so we add sr.otheratts="ALIGN=TOP";.

Rollover Submit Image: Several On One Page >>>

Copyright © 2002-8 Art Dacor USA LLC. All Rights Reserved.
3727 West Magnolia Blvd #489, Burbank, CA, 91505, USA.
www.HTML-HTML.com