HTML Interview Questions & Answers

Define $() in jQuery library?

The $() function is also known as of jQuery() function, at first it looks weird and makes jQuery code cryptic, but once you get used to it, you will love it’s brevity. $() function is used to wrap any object into jQuery object, which then allows you to call various method defined jQuery object. You can even pass a selector string to $()function, and it will return jQuery object containing an array of all matched DOM elements. I have seen this jQuery asked several times, despite it’s quite basic, it is used to differentiate between developer who knows jQuery or not.

List out some web browsers?

Some famous web browsers are Mozilla firefox, safari, Google chrome, opera browser and netscape.

What are the basic editors of HTML?

There are many editors for HTML like EditPlus,Notepad, WYSIWYG, Notepad++,HTML Editors etc.

What are the extensions that supports HTML?

HTML supports both .htm and .html extension.

Does a hyperlink apply only to text?

No. The hyperlinks can be applied to both text as well as the images.

It means that even the images can become clickable links with a capability to take the visitor to the next page.

This can be done simply by using <a href> tag.

How to use JavaScript along with HTML?

JavaScript can be used along with HTML by including <script> tag in the HTML <body> tag.

How to redirect using HTML?

Using HTML, we can redirect users to different webpage.

What are the common lists that can be used when designing the page?

Menu list

ordered list

Definition list

Unordered list

Directory list

How to create Tables using HTML?

HTML tables are created using tags <table>. To divide a HTML table, we have to use <tr>, which is table row. Likewise we <td> and <th>.

What is a web Application?

It is an application using web and web browser technologies to accomplish one or more tasks over a network, typically through a web browser.

What are the different types of Headings supported by HTML?

HTML headings are important to highlight the contents of the documents. HTML supports 6 heading starting from <h1> to <h6>.

How to change background colour using HTML?

The back ground color of HTML can be change attribute bgcolor in the <body> tag.