Posts from JavaScript

Add or append a new item to an array in JavaScript using push() method

By Faruque Ahamed Mollick

In this tutorial, we are going to learn how to append or add a new item to an array using the JavaScript push() method. We will learn with simple example code. JavaScript array pu.... Read More

Replace URL in HTML or text content with clickable link using JavaScript

By Faruque Ahamed Mollick

In this tutorial, we are going to see how to select the URL from text or HTML content or from a string from an element and make it clickable using JavaScript. We are going to use j.... Read More

Locate the Geo-position of a visitor in JavaScript

By Faruque Ahamed Mollick

In this post, we are going to see how to locate the position of a user who is visiting a web page using JavaScript. Today, almost all modern web browsers support the geolocation AP.... Read More

Show and hide password of input box in JavaScript

By Faruque Ahamed Mollick

If we create an HTML input field of type password then we can see that we are not able to see the password. We will see something like “********” instead of the passwor.... Read More

How to generate a random password in JavaScript?

By Faruque Ahamed Mollick

In many times it is needed to generate a random password for a website. For example, on registration system of a website a password can be generated for the account by clicking a b.... Read More

Stop form submission using JavaScript preventDefault() Event Method

By Faruque Ahamed Mollick

In projects, it is often necessary to prevent form submission after clicking the submit button of an HTML form. So in this tutorial, we are going to see how to prevent or stop an H.... Read More

3D Photo/Image Gallery (on space) Using HTML5 CSS JS

By Saruque Ahamed Mollick

Nowadays everybody wants something cool and different on their website from other websites. So here you will find something really cool. Today I am gonna share 3d image gallery. It.... Read More

Guess The Number Game Using JavaScript

By Saruque Ahamed Mollick

In this post, I am going to share a source code of “Guess The Number” game using JavaScript At first, let’s see what kind of game is this and how does it work? Af.... Read More