Featured
-
Top 10 Template Engines for JavaScript
What is a Template engine? Template Engines are
by nishant.mishra -
jQuery Accordion
Hello readers! In this Blog we will gain knowled
by vishwanath.rana -
How to make Numbered and bulleted list in HTML Editor with JavaScript
Hello all, Working with HTML Editor we wanted t
by gaurav.gautam -
How to hide particular div with just one click?
Hi, you want a condition in which the particula
by abhishek.tiwari.458 -
How to Create and Retrieve Array in Javascript?
If you want to store multiple values in a single v
by siddharth.shahi
Tags
Difference between event.stopPropagation(), event.preventDefault() and return false
We have many times have listen about event bubbling in javascript which propogate an event from child element to parent element.
So, to avoid such event bubbling in our page we use event.stopPropogation or return false. Also there is a new thi...
Event bubbling and capturing in javascript
There are two ways of event propagation in HTML DOM, when an event occur in an element with an element:
1. Event bubbling
2. Event capturing
1. Event bubbling : There are many times when we want to handle two or more event handlers at differ...
Difference between Graphics tags Canvas and svg tags
HTML5 has tags for graphics like:
1. Canvas
2. SVG
There are certain differences between the two:
1. SVG is resolution independent while canvas is resolution dependent.
2. SVG supports event handlers while canvas doesnot support event hand...
How to get the first class from multiple class of an element using js with demo
There are certain cases when, we want to get the class of a particular element from multiple classes in that element, you can use the following code:
HTML:
<div id="gettingClass" class="firstClass secondClass">Click o the following ...
Difference between window.onload and document ready
There are some minor difference between the two but it can effect with lots of confusion between to many of us.
window.load - It is fired when everything on the page is loaded. By everything I mean that when the DOM is loaded, when all t...
Chapter 3: Authentication using node.js(passport.js) and mongoDb
As we all know authentication plays an important role in every site. Here In this blog I am explaining how we will authenticate our site in node.js as a backend and mongoDb as a database. To authenticate I am using passport.js which will help to ...
How to send data to another server in node.js
I have a situation in which I want to fetch data from another server. In node.js it is possible to send data to another server. For achieving this task we will use http module. To explain this I have written the code below .
Example:
...
A sliding Fullscreen Navigation Menu
Hello, readers . In today's blog I have tried to create A Full Screen Sliding Navigation covering the full screen using Javascript in a direction from left to right.
For creating this I need to make a div with id name as “m...
Binding options in selectbox at runtime using Angular js with Demo
Hello Readers,
We will add value of input text field in options of select box on blur event. Whatever we type in input text field it will added to the options of select box on blur event.
To understand the full functionality her...
Reinitiate jquery datepicker after append the date field
Hello Dear Readers,
Most of times, when we append the text field of datepicker using jQuery it not work, in other words when we integrate the dynamic datepicker using jQuery append method then datepicker work only with first field.
In this ...
Creating a Stripped-Down Browser Window
Hello reader's in this tutorial we will discuss how to open a new stripped browser window?, Some time we want to open a web page in a new, stripped-down, fixed-size browser window.
To open a new fixed size window we use window.op...
Self-Executing Anonymous Functions in javascript
As we all know in javascript we mostly use function ,if statement,loop and event handlers.These terms help us organize your code into a cohesive, structurally-sound whole.
Let's take one example of javascript function:
var f...
jquery val() method
It is used to set the current value of a particular element in the set of matched elements.
it sets the value of every matched element.
The default value of input field is empty string so it is blank.If user types something in inp...
Scrolling of a sidebar
Below is the code to keep the sidebar fixed while scrolling the page.
It is one of the easiest way to keep it fixed.
HTML-
Here is the simple design having main content div and a particular section of a sidebar.
<div id="main_con...
Bounce Effect using Jquery
Hello Readers, this blog is on the bouncing effect using jquery in all directions(up, down , right and left).
I have created four round boxes, on clicking on a box each box will bounce in a different direction and a button on clicking that but...
Finding a Substring in a String
Hello reader's in this blog we will discuss finding the substring in a string. When you want to find out a particular series of character in a string we use indexOf method to find out our character.
The indexOf() method will find out...
Queue Functionality In jQuery animate()
If we want to create custom animation than for this purpose jquery animation is used.
jquery animation method syntax is below:-
Syntax :-
$(part to be selected).animate({parameters},speed,callback);
Queue functionality of ...
Constructor and Object in JavaScript with example
Constructor, classes, and object are the foundation of OOPS language. In javascript, we also use constructor, classes, and object. I will explain this by using a simple example but before starting this we should know what is constructor, classes,...
Introduction to Object-Oriented JavaScript and namespaces in javascript
There are n number of OOPS functionality available in Javascript. Some of the basic OOPS terminologies are namespaces, classes, object, constructor, method and much more. Now I will explain one by one with syntax and definition of these terms.
...
Difference between Document ready vs Window load
When a person starts programming or executing a function on page load, a common question occurs at that time, that which method we follow to execute the code on page load.
It is quite necessary that programmer needs to integrate some extra act...
How to compare strings conditionally?
Hello reader's in this blog we can discuss about comparison of strings. The strings in javascript are the important component of javascript. When you want to get a numeric values from the web page forms, the values are retrieved as string, wh...
Node.js: How to perform endless loop with async module?
I have a situation where I want to run an endless loop and I have to get data from there. For this, I have to make a Http call and then put the http response in a database, In each iteration, I have to wait for some second.
To solve this...
Chapter 2: How to connect with mongoDb and use mongoDb model using nodeJS
NodeJS is an open source, completely free and javascript based platform built on Google Chrome's JavaScript V8 Engine. In other words, we can say that NodeJS is a cross platform which is used to develop server side web application.
In my p...
Accordian in jquery
Accordian are used when we have to show/hide large amount of content, so it is expandable and collapsible. we can also add symbol to indicate whether collapsible content is open or closed
<!DOCTYPE html>
<html>
<head>
&l...
Rotation of a div using jQuery
There are many ways to rotate a div or a particular block. We can use animate to move a block from one position to another.
Here is a simple way to change the position of a simple block.
HTML:-
<div id="rotator">
<div id="...
How to use jQuery :first Selector?
Hi Reader's,
Welcome to FindNerd, today we are going to discuss how to use jQuery :first Selector?
Basically :first selector is used for selecting the first element and it is always use in a group.
The :first selector&n...
How to use load() method in jquery?
Hi Reader's,
Welcome to FindNerd, today we are going to discuss how to use load() in jquery?
Basically load() method is used for loading data from server and putting return data into selected item,in simple word we can say tha...
Understanding AngularJS Bootstrap Process
Bootstrap process in angularJs is simple and you should know about it. There are two ways of bootstrap process in angularJs:
Automatic Bootstrap
Manual Bootstrap
Automatic Bootstrap:
When we run our angularJs App the DOM(Document Ob...
How to increase and decrease the date by one on click using js?
If the user wants to increase or decrease the date by one, on click of a button, he can easily do this by using the following code.
HTML:
Date: <input type="text" class="dateone" id="datepicker">
<input type="button" onclic...
Understanding Data Binding in AngularJS
In this post, you will learn about the data binding in angularJs. It is one of the powerful feature which angularJs provides.
There is two-way data binding in angularJs to bind data between model and view.
The data binding mechanism is handle...
Slide Element from Left to Right Position
Hello readers,
This is a quite simple blog that will show how to slide a div from left to right using jquery function. Here I have taken two div one is outer that have some property like it is set to at left position and add the background col...
Using href link values inside your select box
In this post, you will learn how to connect select box option with the anchor tag link.
Sometimes you want to change the select box value like an anchor tag with the refresh of page. Lets understand this with an example.
If you have select bo...
Onkeypress Enter focus Input field
Hii,
In this blog I am going to share a javascript code using which we can create a form in which user can fill data without using mouse to move from one input field to another.
You will see that on keypress enter focus will move to next inpu...
How to disable previous dates in datepicker using jQuery?
Hi Readers,
Welcome to FindNerd, today we are going to discuss a method to disable previous dates in datepicker using jQuery?
Datepickers is a very important feature of a web application. It is mostly used in any registration form when ...
Bootstrapping AngularJS
In this tutorial, we are going to discuss Bootstrapping in Angular application and also discuss the ng-app directive. When the document is loaded the ng-app directive will bind the Angular js functions with an application. Ng-app is the simplest ...
Disable the control(ctrl key) plus click event for a particular click with demo
There are many cases where we do not want our page to open in another tab while clicking ctrl+click and the anchor tag is producing dynamically.
For that, we can add the following script which will disable the same effect.
$(funct...
Simple way to validate an empty text box on submit
Validating an empty field on submit through JavaScript
As we know in almost all the web applications we have forms which contain text boxes and text fields to input some data and submit it. Sometimes knowingly or unknowingly users can submit t...
How to check if the scroller reached at the bottom of the page with demo?
There are many techniques through which we can place an event when the scroller reaches the bottom of the page.
If the user wants to play an event when he reach the bottom of the page, he can do the same with the help of the example below:
...
How to pass a function as a parameter in JavaScript?
In Javascript it is possible to pass a function as an argument to another function just like we pass a normal variable to a function.
Suppose i have a requirement that i want to call 2 functions one after the other and the second function has ...
Installation and creating basic project using nodeJS.(Chapter 1)
NodeJS is an open source, completely free and javascript based platform built on Google Chrome's JavaScript V8 Engine. In other words we can say that NodeJS is a cross platform which is used to develop server side web application.
Installa...
Scope in javascript
Hii,
In this blog i am going to discuss about scope in Javascript and how we can use it.
Being a JavaScript developer one should have proper knowledge about JavaScript scope.
JavaScript scope specifies objects,function and set of variabl...
How to append/add and remove input field in a form with just on a click?
Hi Reader's,
Welcome to FindNerd, today we are going to discuss how to append/add and remove input field in a form with just on a click?
In this blog we will see how to append text input fields in a HTML form using jQuery and proces...
jQuery fadeToggle Method
In many sites we have seen that when we click on some button it will make some div faded, this will happen with the help of fadeOut() method in jquery.
If we want some faded div or hidden div to get show, we can do that by using fadeIn()...
How to add a video as background of your website
Hii,
While designing a web page our main motto is to design the web page beautiful and attractive with the help of CSS.
Here is one more option i.e to add a video in the background of a webpage to make it more attractive and beautiful.
Addin...
File validation using javascript
Hii,
File Validator is a function used when we want to restrict the type of file uploaded.
Using File validator we can easily get file Info for each file uploaded.
If uploaded file is not as per the required format a validator func...
Form Validation in AngularJS with ngMessages
In this post, you will learn about ngMessages directive in angularJs and how it can help to show error messages in your application. ngMessages provides custom form validation facility to display error messages in angularJs.
Let’s start ...
What are directives?
Directives are the functions of javascript in Angularjs, the function can run when the DOM is loaded by the angular framework. By this new approach, Angularjs will let you to create a new directive which could manuplate or modify DOM logica...
jquery slideToggle method
In many site we have seen that when we click on some div,other div will slide down from it , this will happen with the help of slideDown() method in jquery.
If we want to make some div to slide up we can do that by using slideUp() method...
Understanding $emit, $broadcast in AngularJS with example
The services yield by Anjularjs which can be utilized for communication based on event between controllers are $on, $emit, and $broadcast. These are under the publish/subscribe design pattern of angularjs i.e. you can publish an event somewhere a...
Objects in javascript
Hii,
In this blog i am going to discuss about objects in Javascript and how we can use it.
While writing client side scripting language i.e Javascript we use concept of OOPs(object oriented programming languages) which helps us to use propertie...