My Life and the world

World changes day by day!

Sunday, April 26, 2015

List of jQuery Selectors

1 comment
The jQuery is the collections of scripts written in JavaScript to perform various task including the document traversal and manipulation, event handling, animation etc. The syntax of jQuery was listed, where we go through the selectors. Now giving you the  complete list of jQuery Selectors.

 jQuery Selectors

  • $('*'): This selector selects all the elements in the document.
  • $("p > *"): This selector selects all elements that are children of a paragraph element.
  • $("#specialID"): This selector function gets the element with id="specialID".
  • $(".specialClass"): This selector gets all the elements that have the class ofspecialClass.
  • $("li:not(.myclass)"): Selects all elements matched by <li> that do not have.
  • $("a#specialID.specialClass"): This selector matches links with an id of specialID and a class of specialClass.
  • $("p a.specialClass"): This selector matches links with a class of specialClass declared within <p> elements.
  • $("ul li:first"): This selector gets only the first <li> element of the <ul>.
  • $("#container p"): Selects all elements matched by <p> that are descendants of an element that has an id of container.
  • $("li > ul"): Selects all elements matched by <ul> that are children of an element matched by <li>
  • $("strong + em"): Selects all elements matched by <em> that immediately follow a sibling element matched by <strong>.
  • $("p ~ ul"): Selects all elements matched by <ul> that follow a sibling element matched by <p>.
  • $("code, em, strong"): Selects all elements matched by <code> or <em> or <strong>.
  • $("p strong, .myclass"): Selects all elements matched by <strong> that are descendants of an element matched by <p> as well as all elements that have a class ofmyclass.
  • $(":empty"): Selects all elements that have no children.
  • $("p:empty"): Selects all elements matched by <p> that have no children.
  • $("div[p]"): Selects all elements matched by <div> that contain an element matched by <p>.
  • $("p[.myclass]"): Selects all elements matched by <p> that contain an element with a class of myclass.
  • $("a[@rel]"): Selects all elements matched by <a> that have a rel attribute.
  • $("input[@name=myname]"): Selects all elements matched by <input> that have a name value exactly equal to myname.
  • $("input[@name^=myname]"): Selects all elements matched by <input> that have a name value beginning with myname.
  • $("a[@rel$=self]"): Selects all elements matched by <p> that have a class value ending with bar
  • $("a[@href*=domain.com]"): Selects all elements matched by <a> that have an href value containing domain.com.
  • $("li:even"): Selects all elements matched by <li> that have an even index value.
  • $("tr:odd"): Selects all elements matched by <tr> that have an odd index value.
  • $("li:first"): Selects the first <li> element.
  • $("li:last"): Selects the last <li> element.
  • $("li:visible"): Selects all elements matched by <li> that are visible.
  • $("li:hidden"): Selects all elements matched by <li> that are hidden.
  • $(":radio"): Selects all radio buttons in the form.
  • $(":checked"): Selects all checked boxex in the form.
  • $(":input"): Selects only form elements (input, select, textarea, button).
  • $(":text"): Selects only text elements (input[type=text]).
  • $("li:eq(2)"): Selects the third <li> element
  • $("li:eq(4)"): Selects the fifth <li> element
  • $("li:lt(2)"): Selects all elements matched by <li> element before the third one; in other words, the first two <li> elements.
  • $("p:lt(3)"): selects all elements matched by <p> elements before the fourth one; in other words the first three <p> elements.
  • $("li:gt(1)"): Selects all elements matched by <li> after the second one.
  • $("p:gt(2)"): Selects all elements matched by <p> after the third one.
  • $("div/p"): Selects all elements matched by <p> that are children of an element matched by <div>.
  • $("div//code"): Selects all elements matched by <code>that are descendants of an element matched by <div>.
  • $("//p//a"): Selects all elements matched by <a> that are descendants of an element matched by <p>
  • $("li:first-child"): Selects all elements matched by <li> that are the first child of their parent.
  • $("li:last-child"): Selects all elements matched by <li> that are the last child of their parent.
  • $(":parent"): Selects all elements that are the parent of another element, including text.
  • $("li:contains(second)"): Selects all elements matched by <li> that contain the text second.
For more detailed documentation on jQuery Selectors visit the Jquery official documentation page about selectors.

Sunday, April 19, 2015

Best Books to learn jQuery

No comments
Learning Jquery is best things to do for a web developer. If you want to boost your  career in the field of web designing and development, learning Jquery is must. Books are great way of learning. So we need some Best Books to learn jQuery. Before we go through the books we choose we need why we learn jQuery and those books. There are many benefits of learning  jQuery -
  • Easy to make beautiful UI design.
  • Get many solutions for you websites.
  • Easy to customize your website with plugins.
  • Use your own widgets and plugin as per your need.
  • Better develop your mobile site.
With the those benefits mentioned above, we can have great experience with jQuery.  To get best in web development we need to increases our skills. The skills in jQuery will boost our growth in the field of web development and web designing. As with jquery we not only will design better UI for desktop but also for mobiles. Get few of the best books and learn Jquery today.

Below is some Best Books to learn jQuery -

             



A part from the above books there few books for quick reference.These books are easier to grab in little times, they are light and easy to get reference. Best Books to learn jQuery for reference purpose are -


Combine the power of jQuery with best blogging platform of WordPress to get excellent result. Buy the book below get  combined result of jQuery and wordpress in your skills.



Also few Best Books to learn jQuery and their purpose and usefulness is listed below.
As per your requirements and your stage of learning choose any of these books and master the power of jQuery. The skill of jquery will help you alot. Good luck !

Saturday, April 18, 2015

Cyanogen releases Lollipop (Cyanogen OS 12 ) update for YU Yureka

No comments

The much waited Lollipop(Cyanogen OS 12 ) update for Micromax YU Yureka is out. Cyanogen OS 12 is take on Android 5.0 Lollipop, by Cyanogen Inc. with some customization. This update was due since YU first reveled on facebook page for 26 March. The update will roll out to every user within 3 days. Check for update in your Yureka phone, go to setting->about phone->system update and check it if available for your phone.


This update will come with Google's Material Design, notification enhancements, multitasking changes and more, there are a few Cyanogen-specific changes as well.

Sunday, April 12, 2015

How to use jquery API

No comments
In the introduction of jquery we told that jquery is the collections of scripts written in JavaScript to perform various task including the document traversal and manipulation, event handling, animation etc. We also expressed some of the benefits of using the jquery libraries.  Now we are talking how to utilize the features of jquery and jquery API.

Including the jQuery library

To use jQuery library, we have to first include it in our web page or link it. The jQuery library is a single JavaScript file which contains all - common DOM, event, effects, and Ajax functions. To take advantage of it just download the javascript file of jquery from the website. After downloading the file, call it in your page.
<script type="text/javascript" src="jquery.js"></script>
Alternatively you can call the api from the internet sites like of Google
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script&gt

jQuery Syntax

The jQuery syntax is very easy, it's tailor made for selecting HTML element(s). After the selection, some action is defined on the element(s) selected .

Basic syntax is: $(selector).action()
  • A $ sign to define/access jQuery.
  • A (selector) to "query (or find)" HTML element(s).
  • A jQuery action() to be performed on the element(s).

jQuery Selectors

The jquery selectors are identical to the CSS selectors. Like CSS, jQuery also uses three different ways of selecting the elements, either by the name, id or the class attributes. These selectors are respectively called as element selectors, id selectors and class selectors.
Tag Attributes Description
Name (element selectors) Uses the tag name available in the DOM. Syntax -  $('element')For example $('p')selects all paragraphs in the document.
ID (#id selectors) Uses the tag available with the given ID in the DOM. Syntax -  $('#idname')For example$('#wrapper') selects the single element in the document that has an ID of wrapper.
Class (.class selectors) Uses the tag available with the given class in the DOM. Syntax -  $('.classname')For example $('.button') selects all elements in the document that have a class of button.
The actions that is performed on the elements are same as the javascript actions.

The Document Ready Function

To load the script as page get loaded, there is ready event in jQuery. Thi helps in manipulating the script as the document is ready. In the ready event function you can call the script written in jQuery.

$( document ).ready(function() {

// Your code here.

});

Final words - These are just basics of jQuery API, how to use them. There are alot more things to go in future posts. Keep in touch and go through them.

Sunday, April 5, 2015

Introduction to Jquery

No comments
Today's is the era of internet. From it's beginning to now, internet have changed time to time. The internet or the world wide web being part of life. From searching things, shopping, listening songs, watching videos, playing games, chatting etc there many things where one engage on internet. It is one of the tool of communication as well as used for entertainment. As internet changes the challenges roses in front of developers.  In this modern fast changing web world developers faced many challenges while designing and developing the websites. Today we introducing, Jquery one of the important technology which changes the way developers designing and developing the websites.



What is Jquery?

The jQuery is the collections of scripts written in JavaScript to perform various task including the document traversal and manipulation, event handling, animation etc. It makes the coding easier for web developers. It helps resolve the cross browser compatibility. See what wikipedia have to say about the jquery -
jQuery is a cross-browser JavaScript library designed to simplify the client-side scripting of HTML
The   jQuery has it slogan of "write less, do more" which it perfectly imitates. With it versatility and extensibility API jquery have helped many developers. With jquery web application or widgets, plugins, extensions etc became easy to design and develop as well as in making them compatible with for future revision.

Advantages of using jQuery

  • Open source libraries.
  • Detailed documentation and examples.
  • Ease to use the scripts.
  • Cross browser compatibility (including IE6).
  • Ajax supports and light weight.
  • Better UI and Mobile design.
More than 65% of websites today using this library. It is the most popular javascript library. It is widely used by most of biggest internet companies like - wikipedia, wordpress, Microsoft etc.

Visit the Jquery website