While using jquery or javascript code most of the time i have to face the problem of jquery or javascript conflict.
Still i haven't got the reason why this stuff get conflict with other code?
Any one have any idea about this?
And any solution so that next time this issue will not occur while project development.
I have one solution to stop the conflict of jquery files that is,
<script>
var j$=jQuery.noConflict();
</script>
but all the time this code is not working.
noConflict()
is for jQuery to get along with other possible libraries that make use of$
variable (for example Prototype is such library). So if you often work with two conflicting libraries on one page, you have to get used to usingjQuery.noConflict
. – WTK Feb 17 '12 at 7:44jQuery.noConflicts()
, may b in header. – diEcho Feb 17 '12 at 7:47jQuery.noConflict
once somewhere after embedding jQuery into to page, and then, instead of dollar sign variable ($
) refer to jQuery by using variable you have assigned it to (j$
in your example). – WTK Feb 17 '12 at 7:50