javascript - Adding jQuery code to wordpress -


I am trying to add the following code to Wordpress but it does not seem to work.

$ (".box"). Hover (function (e) {$ ('. Box')

Please help .not (this) .addClass ('Gray')}, // Over function (e) {$ (' . Box '). RemoveClass (' Gray ')} // External);

You have to wrap it in noConflict mode such as:

  jQuery (function ($) {// using your jQuery code, $}); See  

:

  jQuery (function ($) {$ (". Box") ($ ('. Box'). $ ('. Box '). No (this) .addClass (' gray ');}, // over function (e) {$ ('. Box '). RemoveClass (' isolate);});  

Comments