Jquery Issue

    Date: 09/04/07 (Javascript Community)    Keywords: css

    I'm writing code so that you click on an image, and it shows a hidden div and swaps the image.

    Currently, it animates the hidden div, and swaps the image to the new image, but I can't get it to swap back!

    Any pointers?


    $(document).ready(function() {
    $('div.formHelp > div').hide();
    $('div.formHelp > img').click(function() {
    $(this).next('div').toggle('normal');
    if
    ($(this).attr("src","/images/css/formHintButton.gif"))
    ($(this).attr("src","/images/css/formHintButtonSelected.gif"))
    else
    ($(this).attr("src","/images/css/formHintButtonSelected.gif"))
    ($(this).attr("src","/images/css/formHintButton.gif"))
    return false;
    });
    });

    Source: http://community.livejournal.com/javascript/140135.html

« updating table? || Ajax/Javascript »


antivirus | apache | asp | blogging | browser | bugtracking | cms | crm | css | database | ebay | ecommerce | google | hosting | html | java | jsp | linux | microsoft | mysql | offshore | offshoring | oscommerce | php | postgresql | programming | rss | security | seo | shopping | software | spam | spyware | sql | technology | templates | tracker | virus | web | xml | yahoo | home