- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to search the value of the type attribute of a link in JavaScript?
To search the value of the type attribute of a link in JavaScript, use the type property. You can try to run the following code to get the value of type attribute.
Example
<!DOCTYPE html> <html> <body> <p><a id = "qriesid" href = "https://qries.com/" type="text/html" >Qries</a></p> <script> var x = document.getElementById("qriesid").type; document.write("Value of the type attribute: "+x); </script> </body> </html>
- Related Articles
- How to search the value of the href attribute of a link in JavaScript?
- How to search the value of the target attribute of a link in JavaScript?
- How to get the value of the type attribute of a link in JavaScript?
- How to get the value of the hreflang attribute of a link in JavaScript?
- How to get the value of the rel attribute of a link in JavaScript?
- How to get the value of the target attribute of a link in JavaScript?
- How to get the value of the id attribute a link in JavaScript?
- How to find the href attribute of a link in a document in JavaScript?
- How to search the querystring part of the href attribute of an area in JavaScript?
- How to get the value of the usemap attribute in JavaScript?
- How to change the value of an attribute in javascript?
- How to get an attribute value from a href link in selenium?
- How to search and display the pathname part of the href attribute of an area with JavaScript?
- How to get the value of the usemap attribute of an image with JavaScript?
- Role of media attribute on the LINK element

Advertisements