WebDeveloper.com ®: Where Web Developers and Designers Learn How to Build Web Sites, Program in Java and JavaScript, and More!   
Web Developer Resource DirectoryWebDev Jobs  
Animated GIFs
CSS
CSS Properties
Database
Design
Flash
HTML
HTML 4.01 Tags
JavaScript
.NET
PHP
Reference
Security
Site Management
Video
XML/RSS
WD Forums
 Client-Side
  Development

    CSS
    Graphics
    HTML
    JavaScript
    XML
    Dreamweaver/FrontPage
    Multimedia
    Web Video
    General
    Accessibility

 Server-Side
  Development

    ASP
    Perl
    PHP
    .NET
    Java
    SQL
    Other

 Web Development
  Business Issues

    Business Matters
    Website Reviews

 E-Commerce
    Domain Names
    Search Engines

 Etc.
    Computer Issues
    Forum Software
    Feedback
    The Coffee Lounge



Script Downloads
Disable Form Buttons

Featured: July 23, 2008
Description: This script will disable your submit button in order to prevent multiple form submissions. Easy to implement.

Get Script

Hosting Search
Unix   Windows
PHP   Webmail

Sign up for the free WebDeveloper E-mail newsletter!


JupiterWeb Commerce
Partners & Affiliates
Partner With Us
Car Donations
Prepaid Phone Card
Auto Insurance Quote
Televisions
Disney World Tickets
Imprinted Promotions
Compare Prices
Dental Insurance
Compare Prices
Find Software
KVM over IP
Baby Photo Contest
Shop Online
Corporate Gifts

internet.com
IT
Developer
Internet News
Small Business
Personal Technology
International

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers
Access FREE Mainsoft Tools:
Access FREE Mainsoft Tools:
Demo:
Integrate Microsoft SharePoint into IBM Lotus Notes
Mainsoft's SharePoint Integrator for Lotus Notes is an easy-to-deploy, client side plug-in that gives Notes users easy access to Microsoft SharePoint document libraries. SharePoint Integrator makes collaboration easy for enterprises that use Lotus Notes and have workgroups that rely on SharePoint for basic document management and team collaboration.

Just because Web sites are easy to build these days, that doesn't mean it's easy to build a quality Web site that meets your business objectives.

Before developing your next Web site, or redesigning an existing site, download this Internet.com eBook to guide you through the process and plan your project, whether you're developing a site in-house or outsourcing the project.
Register now for your free Internet.com membership to download your complimentary eBook. Membership will also give you access to:

eBook library         Whitepapers         Webcasts
Newsletters         WinDrivers

Pre-loading Images and Creating MouseOver Effects in JavaScript

by Scott Clark and Ronnie Moore
First published: January, 1999

We show you how to do it, and even do it for you using our nifty script generator!

Some of the most common questions we're called upon to answer from our readers are "How can I preload some images for use in a mouseover effect?" and "How can I make an image change when the mouse is moved over it?" In this tutorial, we're going to show you how to perform both tasks, and we're even going to provide you with a Preload/Rollover Script Generator, created especially for our readers.

To get started, check out our Preload - Rollover Script Generator. Fill in the empty form fields, three for each preload/rollover effect you wish to use. The first field is for the initial image which will be shown on your page. You can use a relative URL for the image, such as alien1.gif, or you can use the full URL, like http://webdeveloper.com/javascript/alien1.gif. The second field is where you'll place the URL for the rollover image--the one that will be pre-loaded. Again, you can use a relative or a full URL. The third blank is where you'll place the URL for the hyperlink itself, such as http://www.webdeveloper.com. Continue in this fashion until you have listed all the images you wish to use as mouseovers (you can create five pre-loads/mouseovers using the generator), and then click the button on the bottom of the page.

The JavaScript code for your pre-load and your mouseover effects will be generated in the large form field at the bottom on the page. Now you'll want to cut and paste the code into your own HTML page. Place the script itself in the HEAD of your document, and then place the mouseover code where you want it to appear in the BODY of your document. The generator automatically creates the HEAD and BODY tags, but these are mostly so you'll get a better idea of where each section goes.

Here's the way it works: As the page is loading the initial images, it also pre-loads the mouseover images. As the mouse is moved over the initial image, the script changes the source for the image to the (new) mouseover image. When the mouse is moved off the image, the script changes the source back to the original image. Simple, yet elegant! This works for and with both Netscape and MSIE browsers, so have phun!




Acceptable Use Policy

JupiterOnlineMedia

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info


Legal Notices, Licensing, Reprints, & Permissions, Privacy Policy.

Web Hosting | Newsletters | Tech Jobs | Shopping | E-mail Offers