Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Front End Technology Articles - Page 552 of 860
1K+ Views
In this article we are going to discuss how to find the number of links in a document in JavaScript. The DOM property in the JavaScript provides many properties like , , , , , . There are two ways through which we can represent the links in HTML DOM. The DOM object provides links property. The document.links property provides us a collection of and tags inside a document. The document.links property is similar to an array. We can access any property (like href, name, title) of the links using this property. To find the total number of ... Read More
2K+ Views
In this article we will learn how to get a particular anchor in a document in JavaScript. The Javascript anchor tags follow an array-like structure. When we try to display a particular anchor tag we have to use ,document.anchors.innerHTML method. This method works the same as array methods which are used to display a particular element. To get a better understanding let’s look into the usage and syntax of anchor tag in JavaScript. Syntax The syntax to get a particular anchor tag is shown below. document.anchors[i].innerHTML or document.getElementsByTagName(“a”)[i].innerHTML Example 1 The following is an example program to get a ... Read More
1K+ Views
This article discusses about how to find the number of anchors in a document in JavaScript. The anchor tag is a part of HTML DOM elements. The anchor property is a read only property that returns a list of anchor tags inside a document. The anchor object is represented as . There are two ways to get the length of the anchors object. One way is to use the anchors.length property that returns the number of anchor tags in a document. The other way is to use getElementByTagName method to access the anchor tag and use the length property. Both ... Read More
1K+ Views
In this article we will learn how to get the title and full URL of a document in JavaScript with the help of examples. The Javascript HTML DOM has provided some basic methods to access and manipulate the HTML data. To find the title and URL of a document, JavaScript has provided document.title and document.URL respectively. The document.title property − The document.title property returns the current title of the document. This property applies to HTML, SVG, XUL, and other documents. The syntax to get the title of the document is shown below. document.title The document.url property − The URL ... Read More
7K+ Views
First, let us understand how attributes work in JavaScript. Any element's attributes can be changed with JavaScript. The attributes property stores them, and invoking it gives you direct access to them. If we target an element with a class, the class will also appear as an attribute, and we can actually utilize these attribute methods to change classes if we so choose. Now, keep in mind that while we have designated the properties and methods for classes, you can also utilize all of these characteristics to manipulate classes in any element if necessary. href attributes in JavaScript In the href ... Read More
128 Views
The HTML DOM Input Time stepUp() method defines the number of minutes the Time field should increase.SyntaxFollowing is the syntax −Calling stepUp() method with a number, which by default is equal to 1inputTimeObject.stepUp(number)ExampleLet us see an example of Input Time stepUp method − Live Demo Input Time stepUp() form { width:70%; margin: 0 auto; text-align: center; } * { padding: 2px; margin:5px; } input[type="button"] { border-radius: 10px; } Time-stepUp( ) ... Read More
100 Views
The HTML DOM Input Time stepdown() method defines the number of minutes the Time field should decrease.SyntaxFollowing is the syntax −Calling stepDown method with a number, which by default is equal to 1inputTimeObject.stepDown(number)ExampleLet us see an example of Input Time stepDown method − Live Demo Input Time stepDown() form { width:70%; margin: 0 auto; text-align: center; } * { padding: 2px; margin:5px; } input[type="button"] { border-radius: 10px; } Time-stepDown( ... Read More
207 Views
The HTML DOM Input Time step property determines the legal intervals for only seconds.SyntaxFollowing is the syntax −Returning number valueinputTimeObject.stepSetting step attribute to a number valueinputTimeObject.step = numberParametersParameter number values −secondsvalid values constitute of those numbers that divide 60 perfectly (eg: 10, 15, 20)ExampleLet us see an example of Input Time step property − Live Demo Input Time step form { width:70%; margin: 0 auto; text-align: center; } * { padding: 2px; margin:5px; } input[type="button"] { ... Read More
154 Views
The HTML DOM Input Time required property determines whether Input Time is compulsory to set or not.SyntaxFollowing is the syntax −Returning boolean value - true/falseinputTimeObject.requiredSetting required to booleanValueinputTimeObject.required = booleanValueBoolean ValuesHere, “booleanValue” can be the following −booleanValueDetailstrueIt is compulsory to set the time field to submit form.falseIt is the default value and to set time field is not compulsory.ExampleLet us see an example of Input Time required property − Live Demo Input Time required form { width:70%; margin: 0 auto; text-align: center; } * { ... Read More
138 Views
The HTML DOM Input Time readOnly property sets/returns whether Input Time can be modified or not.SyntaxFollowing is the syntax −Returning boolean value - true/falseinputTimeObject.readOnlySetting readOnly to booleanValueinputTimeObject.readOnly = booleanValueBoolean ValuesHere, “booleanValue” can be the following −booleanValueDetailstrueIt defines that the input time field is readOnly.falseIt defines that the input time field is not readOnly and can be modified.ExampleLet us see an example of Input Time readOnly property − Live Demo Input Time readOnly form { width:70%; margin: 0 auto; text-align: center; } * { padding: 2px; ... Read More