JavaScript Tutorials, Tips & Tricks

JavaScript is an open scripting language that enables Web authors to design interactive sites. Can interact with HTML source code and is supported by most browsers.

AngularJS: Introduction and Hello World example

AngularJS: Introduction and Hello World example
AngularJS, a JavaScript framework developed by a Googler and supported by Google has become quite a buzz word in past few months. More and more developers are using it and thus the community has grown significantly. Not only they love it, but they can't stop praising it :)The reason is very simple. AngularJS rocks \m/ !! ...

Lazy Load Image & WordPress Gravatar using JavaScript / JQuery

Lazy Load Image & Wordpress Gravatar using JavaScript / JQuery
A webpage load time plays a very crucial role in SEO and impacts your website ranking significantly. Google has already incorporated site speed as one of the several signals that it uses to determine search ranking. The faster your website loads the better it will perform in google ranking.There are several things one can do ...

21 JavaScript Tips and Tricks for JavaScript Developers

21 JavaScript Tips and Tricks for JavaScript Developers
If you are doing lot of JavaScript programming, you might find below list of code snippets very useful. Keep it handy (bookmark it) and save it for future reference.Here are 20 very useful JavaScript tips and tricks for you.Disclaimer: Not all these snippet are written by me. Some of them are collected from other sources ...

How to convert Javascript Arrays to CSV (Comma separated values)

Let's see a small code snippet in Javascript that converts JS arrays in Comma separated values. It is also possible to convert an array to delimited text where one can choose the separator.var fruits = ;var str = fruits.toString();//print str: apple, peaches, oranges, mangoesThe toString() method converts an array into a String and returns the result. The returned string will separate the elements in ...

jQuery :not() selector example

jQuery :not() selector example
It's been a while since I wrote about JQuery. I am spending most of my time these days on backend technologies. Recently while working on a typical requirement on UI, I had to play with some tricky JQuery selectors.Typically, most of the times we uses JQuery's class selectors or id selectors for example:$('#someid').hide(); $('div#container').css('height', '100%');$('.someclass').hide(); $('div.entry').css('height', '100%');But recently I had a requirement where I had to ...

Deleting Multiple Values From Listbox in JavaScript

Deleting Multiple Values From Listbox in JavaScript
There was a requirement of deleting multiple options from a listbox using JavaScript. User can select multiple items from a Listbox. Once the delete button is pressed, remove all the values that are selected from the combobox.Now the most intuitive solution for this problem would be to iterate through each option from the listbox and ...

STOP SOPA JQuery Plugin

STOP SOPA JQuery Plugin
Right now, Internet is experiencing the biggest protest since its inception. We have seen people protesting against Companies, Government, Dictators etc. Also Internet has become their voices in form of Twitter & Facebook.But today we saw something completely new. Major websites such as Wikipedia and Google are openly demonstrating their protest against new legislation bills ...

Facebook Style Scroll Fixed Header in JQuery

While doing some UI changes of a website, we had to implement a FIX header which remains fix on top of screen while scrolling. Facebook has a similar header which remains on top of content.Now for this, there are number of jQuery plugins available out there! But in our case we weren't allowed to add any new plugins to the technology stack of application ...

Create ZIP Files in JavaScript

Create ZIP Files in JavaScript
Zip is a very useful file type if I must say most used. It is the most used file format for data compression and archiving. There are number utilities available to create/generate Zip file. Also most of the programming languages comes up with API supporting to generate Zip files. I have written a couple of articles ...

Create a Clearable TextBox with jQuery

Create a Clearable TextBox with jQuery
Recently I came across a wonderful article by David Walsh on Clearable Textboxes with Dojo Toolkit . This is a simple implementation where a clear button (x) added in a textbox which lets user to clear the content of the textbox. I have seen this simple feature in many websites and feel its very ...
Page 2 of 812345...Last »