Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5

Thread: Fading Links

  1. #1
    New Coder
    Join Date
    Mar 2003
    Location
    USA
    Posts
    99
    Thanks
    24
    Thanked 0 Times in 0 Posts

    Fading Links

    How can you make links slowly fade into their color?

    Here's an example:
    http://www.universalpalace.net/Sy/?asd=home

    Just hover over a link and it changes color slowly, so can you tell me how to do it?

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Probably using the proprietary filter CSS MS added to IE since a quick look at the html shows the links all have a class named "fade" declared.

    Go to the MS web site and search with "Filter CSS HTML" as your keywords and you should get some results.
    Check out the Forum Search. It's the short path to getting great results from this forum.

  • #3
    Regular Coder
    Join Date
    Apr 2003
    Location
    Atlanta, GA
    Posts
    487
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Sorry, Roy, it's standard spaghetti DHTML stuff, located in their "head.js" file.

    Some of the more painful bits include
    Code:
    document.onmouseover = domouseover;
    ...
    function domouseover() {
      if(document.all){
      	var srcElement = event.srcElement;
      	if ((srcElement.tagName == "A" && autoFade) || srcElement.className == "fade" || (sloppyClass && srcElement.className.indexOf("fade") != -1))
            fade(startColor,endColor,srcElement.uniqueID,stepIn);      
       }
    }
    ...
    if (!document.all)
    return
    - and that's just some of the low-lights.

    Blatch, if you have any aptitude for scripting, you should be able to come up with a solution much nicer than this. Hell, I might give it a shot tonight if I'm not busy.

  • #4
    Regular Coder
    Join Date
    Jun 2002
    Location
    Atlanta, GA.
    Posts
    313
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Google Search "Link Fader"

  • #5
    Regular Coder
    Join Date
    Jul 2003
    Location
    Massachusetts
    Posts
    472
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Roy, your script was the fourth hit. Very cool.
    Moderator @ WebDeveloper.com
    Mentor @ WebXpertz.net


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •