Link to home
Start Free TrialLog in
Avatar of wsessoms
wsessoms

asked on

JQuery help needed

I am new to javascript but slowly learning. i am working on a photography website and I need help with the following:
I found the script below on a JQuery website that works perfectly.  What it does is load an image into the <h3> element when a link is clicked.
What I need is to put a thick white border around the images that are loaded into the <h3> element.
Below is the code.
I need to use this code with the additional functionality; to add the thick border to the image that is loaded into the <h3> element

Thanks in advance for your help.

$(function()
{
    $("#imageOptions a").click(function()
        {
        var imageSource = $(this).attr("href"); 
        $("#loader").addClass("loading");
        $("h3").remove();
          showImage(imageSource);
          return false;
        });
});
function showImage(src)
{
$("#loader img").fadeOut("normal").remove();
var largeImage = new Image();
$(largeImage).load(function()
                        {
                        $(this).hide();
                        $("#loader").append(this).removeClass("loading");
  
                        $(this).fadeIn("slow");              
                        });    
$(largeImage).attr("src", src);                                                                               
}

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of hampus_b
hampus_b
Flag of Sweden image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of wsessoms
wsessoms

ASKER

hampus_b:
Thanks hampus_b.