JavaScript setHours() method sets the hour of a date object. JavaScript getHours() method returns the hour (from 0 to 23) of the specified date and time. Using JavaScript setHours() and getHours() method you can easily add hours to Date object.

By: CodexWorld Aug 12, 2016

If your chrome version is 50, then you’ll encounter that HTML5 Geolocation API is not working. In Chrome version 50, HTML5 Geolocation delivered over HTTP no longer supported by Chrome. The getcurrentposition() and watchposition() are deprecated on insecure origins in Chrome 50.

By: CodexWorld Jun 9, 2016

JavaScript Date object help us to work with dates. Use new Date() to create a new object with current date and time. From Date object you can get current date in Y-m-d format and current time in H:i:s format.

By: CodexWorld Sep 24, 2020

In jQuery Ajax, you can post the data separately. But when you needs to send the entire form data, it is very difficult to get all the form data individually and put together in data settings of Ajax. The jQuery .serialize() method makes this process easier.

By: CodexWorld Feb 4, 2016

It’s very effective way to pass a value with the URL and load the web page based on that value. Using JavaScript you can easily get the value after the hashtag (#) from the URL, there are no need to use jQuery. Also, you can get the hash value from href using simple JavaScript code.

By: CodexWorld Jan 27, 2016

Email input field validation is mandatory before submitting the HTML form. Email validation helps to check if a user submitted a valid email address or not. Using regular expression in JavaScript, you can easily validate the email address before submitting the form.

By: CodexWorld Dec 30, 2015

To track the user online status, you need to maintain a flag in the database. You should need to update this flag when user will log out by the Logout link. If the user closes the browser without clicking the logout button, the browser close event detection would require for updating the flag in the database.

By: CodexWorld Dec 15, 2015

Many times you need to validate the text field for special characters and HTML tags in jQuery validation. JavaScript test() function allow you to check special character.

By: CodexWorld Nov 21, 2015
keyboard_double_arrow_up