HTML Interview Questions and Answers

What is the html frame?

With frames, you can display more than one HTML document in the same browser window. Each HTML document is called a frame, and each frame is independent of the others.

Are there any problems with using frames?

It is difficult to bookmark - and impossible to link or index - such a frameset state. 
Basic browser functions (e.g., printing, moving forwards/backwards in the browser's history) behave differently with framesets. Also, browsers cannot identify which frame should have focus, which affects scrolling, searching, and the use of keyboard shortcuts in general.

How do you target a specific frame from a hyperlink?

Include the name of the frame in the target attribute of the hyperlink.

Ex:

<a href="mypage.htm" target="myframe" >My Page </a>

How do I make a picture as a background on my web pages?

Point the body background to the name of your image you wish to use as the background as shown below. This body line should be the first line after your </head> tag. 
<body background="picture.gif" >

How do I add scrolling text to my page?

Keep in mind not all browsers support scrolling text. however to do this add a marquee tag similar to the below example. 
<marquee>i m scrolling </marquee> 

i m scrolling
How do I make a picture a link?

Use the A HREF link tag around the IMG image tag as shown below. 
<A HREF="http://www.webiwip.com" > <IMG SRC= "title.gif" /> </A>

How do I make my page automatically jump to another page after a specified time?

the META tag is used for redirecting users to another page after a specified amount of time. Simply include the following tag in your page, where x is the number of seconds to wait until redirection, and http://www.someurl.com/ is the URL that the user is being directed to. (The tag must be placed between the <head> and </head> tags.) 

<META HTTP-EQUIV="refresh" CONTENT="x"; URL="http://www.webiwip.net" />

Why Always Close Your Tags?

this is simply bad practice and should be 100% avoided. Always, always close your tags. Otherwise, you'll encounter validation and glitch issues at every turn.

Can you align a table to right or left?

Yes,To align the table to the right, you can use <TABLE ALIGN="right"> for the left, you can use <TABLE ALIGN="left">

Why we Consider Placing JavaScript Files at the Bottom?

the primary goal is to make the page load as quickly as possible for the user. When loading a script, the browser cannot continue on until the entire file has been loaded. Thus, the user will have to wait longer before noticing any progress.

If you have JS files whose only purpose is to add functionality we can place those files at the bottom, just before the closing body tag. This is absolutely a best practice.

What are the different types of Headings supported by HTML?

Html supports six heading starting from H1 to H6

What are differences between DIV and SPAN?

DIV is a block-level element and used as a container for HTML elements whereas a SPAN is an inline elementand working as a container for text;

Latest Updates

Fill in the blank

I ________ station before the train arrived.

If I ______ a king, I would help everyone.

Radha___________her daughter for an hour.

Errors Identification

Find out which part of the sentence below has an error and mark the option accourdingly -
Sohan was married in 1990 and have three children.

Find out which part of the sentence below has an error and mark the option accourdingly -
There is no money in the bank in Ram Singh's and Rama's joint account.

Direction

Swapnil start from his home and walked 35 km towards east, after that he turned to his right and walked 20 km. He again turned to his right and walks 35 km. Finally, he turned to his left and walked 20 km and reached his office. How far is his office from his home?

Numbers

How many 2 digit numbers are divisible by 6?

HCF and LCM

Find the smallest square number which is exactly divisible by 3, 5, 15, 18, 20 and 24?

HCF and LCM of two numbers are 82 and 574 respectively. if one of the numbers is 287, find the second number?

Numbers

How many numbers between 1200 to 1500 are multiple of 13?

Find the total number of terms in the series : -3, 1, 5, 9,............., 101 ?

Find the sum of the first 20 terms of the series : 8, -3, 11, -6, 14, -12, 17, -24,....... ?

Series

Find the missing term in the given series - 101, 120, 145, 168, (?), 224

Find the missing term in the given series - 11A13, 17E19, (?), 31O37, 41U43

Find the missing term in the given series - 2,4,8,3,9,27,4,16,(?),5,25,125

Agriculture

Which gas is fixed by Rhizobium bacteria present in the root nodules of a pea plant ?

Chemistry

The formation of sulphurous acid involves ?

The acid present in soft drinks is ?