Technology Programming

How to Make a Mouse-Over Button

    • 1). Open your program. In this example we will be using Microsoft Paint, although you can use any image editing program you prefer, such as Photoshop. In Windows 7, click the Start button, type "Paint," and hit Enter.

    • 2). Design your button. In the Image section under the Home tab, click Re-size and select the Pixels radio button. Making sure the "Maintain Aspect Ratio" box is unchecked, enter your desired button size in the Horizontal and Vertical boxes and click OK. Use the tools within the program along with your own creativity to create your button.

    • 3). Finish and save your file. Use the blue button on the top-left of the window to bring down the menu and choose Properties. Select the Pixels radio button and change the height to exactly twice the current size and click OK. You're now creating the rollover image directly below your original button. Once you are finished, click the floppy disk on the very top of the program window and save your file, using PNG format in Paint to avoid color distortion. Upload this image file to your web server or image hosting site.

    • 4). Add the following code to your webpage within the <HEAD> tag:

      <style type="text/css">

      #button {

      display: block;

      width: ###px;

      height: @@px;

      background: URL("button.gif") no-repeat 0 0;

      }

      #button:hover {

      background-position: 0 -@@px;

      }

      #button span {

      position: absolute;

      top: -999em;

      }

      </style>

      Replace all hash signs (#) with the width of the button, and all at symbols (@) with the height of the button (before you doubled it). Replace button.gif with the full URL to your image.

    • 5). Add the following code in your <BODY> tag where you would like the button to appear:

      <a href="/links/?u=URL" title="Button"><span>Button Text</span></a>

      Replace "URL" with the URL to the page the button is linking to.

    • 6). Test your new button on your website. If you are using the button for navigational purposes, you may want to make several more!

SHARE
RELATED POSTS on "Technology"
Blitzerwarner: Could You Escape the Speed Cameras?
Blitzerwarner: Could You Escape the Speed Cameras?
What Makes a Perfect Web Design Company?
What Makes a Perfect Web Design Company?
Inside No-Fuss Products In Gaming Computers
Inside No-Fuss Products In Gaming Computers
Gaming Institute, Game Design Schools at PAI-ILS, PAI International Learning Solutions Pune
Gaming Institute, Game Design Schools at PAI-ILS, PAI International Learning Solutions Pune
Free Music Players For Websites
Free Music Players For Websites
'See How NCP Tracks Down Fake Ration Card Holders'
'See How NCP Tracks Down Fake Ration Card Holders'
You Can Stop Panic Attacks in Just two Minutes
You Can Stop Panic Attacks in Just two Minutes
WordPress Blog to WP Site! A Journey to Online Success
WordPress Blog to WP Site! A Journey to Online Success
Videos will give your business portal an extra leverage
Videos will give your business portal an extra leverage
Excellent Ways To Make Weight Loss Work For You
Excellent Ways To Make Weight Loss Work For You
Five Notable Differences between National and International Logo Designs
Five Notable Differences between National and International Logo Designs
Who Should Your Phoenix Web Design Client Be?
Who Should Your Phoenix Web Design Client Be?
White Papers & Other Documents - including ALFLB
White Papers & Other Documents - including ALFLB
Google Analytics Tips
Google Analytics Tips
Want To Make Your Website Faster? Follow These Steps
Want To Make Your Website Faster? Follow These Steps
The Starting of Couture Apparel
The Starting of Couture Apparel
Choose Custom Website Design Services
Choose Custom Website Design Services
Choosing the Right Joomla CMS Developer
Choosing the Right Joomla CMS Developer
A Look at SQL Server Denali AlwaysOn
A Look at SQL Server Denali AlwaysOn
4 Tips to Choose the Perfect Flash Animation Course
4 Tips to Choose the Perfect Flash Animation Course

Leave Your Reply

*