0

The HTML:

<!DOCTYPE HTML>
    <head>
        <link rel="stylesheet" type="text/css" href="/Users/Alireza/Desktop/Index.css" />
        <script src="http://www.ajax.googleapis.com/ajax/libs/jqueryui/1.9.1/jquery-ui.min.js"></script>
        <script type="text/javascript" src="/Users/Alireza/Desktop/Index.js"></script>
    </head>
    <body>
        <div></div>
    </body>

The CSS:

div{
    height: 100px;
    width: 100px;
    background-color: red;
    border: 4px dashed #00FF00;
}

The jQuery:

$(document).ready(function(){
    $('div').click(function(){
        $('div').effect('explode');
    })
})

Please help me. I really don't know why it isn't working. Go ahead and try the code if it helps you. Thank you, in advance.

3
Contributors
5
Replies
30
Views
4 Years
Discussion Span
Last Post by pars99
0

What was the problem and how did you fix it?

Well, whenever I clicked on the <div>, it wouldn't do anything. So, I updated the link and gave the <div> a class of "div". That was so the effect specifically, and only, acted on the one <div>. Updating to the newest version of the jQuery UI also helped.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.