Joe Whitten Blog : Theology, Rants, Photography, Politics, Denver, Colorado

What is so Cool About JQuery?

by admin on Jul.05, 2009, under Information Technology

JQuery is a wrapper for javascript. It combines multiple javascript commands making it much easier to traverse the DOM on web pages. Creating dynamic menus, image presentations and other similar tasks is made much easier due to fewer lines of code being necessary. With JQuery you can dynamically change styles by reassigning classes from your CSS, hide and show elements (blocks, div, p etc…).

JQuery syntax may seem a bit strange when you first look at it, but I found that after working with it for a few hours it is not that difficult to grasp and it is very versatile. JQuery provides multiple routes to an object. Objects can be accessed by the div element they reside in, by the ID of the object, by the class of the object and so on.

An example of hiding a div element on the mouseleave event…

$(“div.menu_body”).mouseleave(function()
{
$(“div.menu_body”).slideUp(300);
});

The above code is applied to all div elements with the CSS class menu_body assigned to them.

I placed a Simple JQuery Menu Example here for you to see and the Style sheet and HTMLzipped if you want to download it and have a look. I’ll try to post some more later. I do most of my development with .Net. In the next post I’ll have an example of the menu in an ASP.Net page.

If you want to know more go to the official JQuery Site and read all about it. You can download JQuery free and use it in your own pages. The JQuery site also contains excellent tutorials to help get you started. JQuery will be a part of the next release of Visual Studio.

  • Share/Bookmark
No comments for this entry yet...

Leave a Reply

You must be registered to post comments. All comments must be approved before they will appear on the site. This prevents spamming. Sorry for the inconvenience.

You must be logged in to post a comment.

Now to him who is able to keep you from stumbling and to present you blameless before the presence of his glory with great joy, to the only God, our Savior, through Jesus Christ our Lord, be glory, majesty, dominion, and authority, before all time and now and forever. Amen. (Jude 1:24-25, ESV)

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!