Category Archives: jQuery

Hide Dropdown list when clicking outside

If you are working on menu creation or anything interactive and your need is to automatically close drop-down as soon as you click anywhere on your page, you can achieve the same by using below code via jQuery: Please share …

Read more »

Easiest way to jQuery Ajax call in ASP.NET

This article is all about calling an Ajax request to an ASP.NET based website. Most efficient and easiest way to implement Ajax request-response flow in ASP.NET is using Web-Method. Basically, as in general if we require to call ajax in …

Read more »

animated image not moving/animating in IE(Internet Explorer)

If you are having Problem showing loader GIF in Internet Explorer or any animated image. You can use a css trick via javascript for the same. Pre-load loader image and insert it via JavaScript on run time.

Prevent bubbling in javascript/jquery

Whenever an event on an element is triggered, it bubbles up through all its parents till it reaches the html element. i.e If we trigger a click event on element1 then all the click events of its parents will be …

Read more »

learn jQuery in single move

Please refer following PPT to learn jQuery in single move. The Magic Of JQUERY By Anoop _ Revised Let me know if any ?’s

Number Validation on text field in jquery/javascript

If you want client side validation on the text field to accept only numbers, then you can use the below function : The above function return true if number is entered, else false. Call this function on keypress() event as …

Read more »

Dimensions in jQuery

If you want to play with an element using jQuery, Your requirement is to measure dimension of the same. You can refer following example: If you have any questions, Please feel free to ask. — Anoop kumar sharma

css manipulation in jQuery

if you want to set style of an element(s), you can refer following example for your reference: Queries are most welcome. — Anoop kumar sharma

Setting attributes of an element in jQuery

To set single/multiple attributes of an element in jQuery, refer following snippet: For any query. Reach me. — Anoop kumar Sharma

Delete or remove an element in jQuery

To delete an element from dom, you need to choose any one of following whichever suites your purpose better: ?’s, let me know. — Anoop Kumar Sharma