In JavaScript, there are several ways to count the occurrences of some text or character in a string. If you need to find the occurrences of a single character, then using the charAt() method inside a loop is the easiest method. Let's look at some examples.

There are dozens of jQuery plugins on the internet to help you create beautiful galleries. Most of them are more aesthetic than functional. This script helps you create a simple and lightweight jQuery photo gallery using unobtrusive JavaScript technique which allows users who have their JavaScript off still use the gallery.

A popular question on forums is how to create random numbers in jQuery. We don't really need to use jQuery for a simple task like this. The Math.random() method in JavaScript can be used to quickly create a random number between 0 and 1

We, as programmers often need to generate random numbers in different application. Generating a random integer in javascript can be done using the Math.random() method. In fact it is one of the several ways that we can use to generate a random number with javascript.

Creating standard-compliant websites is principal aspect of our work. To test if your page is in quirks mode mode you can simply bookmark this JavaScript code on your browser and hit it while viewing the page that you want to find out its rendering mode.