Ask your JavaScript questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

point everything except the elements ( and .myClass) JavaScript

i have a question :
i use "ouseover" and i want to point all elements but not <p> and not .myClass

something like that :

$(allElements).not('p, .myClass').mouseover();

Answers (2)


Christianto answers:

Is this working on your site?

jQuery('*').not('p, .myClass').mouseover(function(){
// your function here

or you can use on()
jQuery('*').not('p, .myClass').on('mouseover', function(){
// your function here

"*" mean select all element [[LINK href=""]]more info here[[/LINK]]

hope this help


Martin Pham answers:

Please try this example:[[LINK href=""]][[/LINK]]