Web Programming Viva Questions
Web Programming Viva Questions
As: The <hr /> tag is used to create an horizontal rule (line).
As: <b> for bold, <i> for italic, <u> for underline etc.
9. What is a hyperlink?
the web.
As: In HTML, images are defined with the <img> tag. The <img> tag is empty, which means that it contains attributes only and it
has no closing tag. To display an image on a page, you need to use the src attribute. Src stands for "source". The value of the
src attribute is the URL of the image you want to display on your page. The syntax of defining an image: <img src=”url/”>
As: Tables are defined with the <table> tag. A table is divided into rows (with the <tr> tag), and each row is divided into data
cells (with the <td> tag). The letters td stands for "table data," which is the content of a data cell. A data cell can contain text,
images, lists, paragraphs, forms, horizontal rules, tables, etc.
As: three types of lists are available <ul> for unordered list, <ol> for ordered list, <dl> for definition lists.
As: A form is an area that can contain form elements. Form elements are elements that allow the user to enter information (like
text fields, textarea fields, drop-down menus, radio buttons, checkboxes, etc.) in a form.A form is defined with the <form> tag.
As: 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.The disadvantages of using frames are: • The web developer must keep
track of more HTML documents • It is difficult to print the entire page
As: When a browser reads a style sheet, it will format the document according to it. There are three ways of inserting a style
sheet:
External Style Sheet :An external style sheet is ideal when the style is applied to many pages. With an external style sheet, you
can change the look of an entire Web site by changing one file. Each page must link to the style sheet using the <link> tag. The
<link> tag goes inside the head section.
Internal Style Sheet :An internal style sheet should be used when a single document has a unique style. You define internal
styles in the head section with the <style> tag
As: The CSS syntax is made up of three parts: a selector, a property and
a value
. What is Javascript?
As: JavaScript is THE scripting language of the Web.JavaScript is used in millions of Web pages to add functionality, validate
forms, detect browsers, and much more. JavaScript gives HTML designers a programming tool JavaScript can put dynamic text
into an HTML page JavaScript can react to events JavaScript can read and write HTML elements – JavaScript can be used to
validate data – JavaScript can be used to detect the visitor's browser – JavaScript can be used to create cookies
As: XML stands for EXtensible Markup Language. XML was designed to transport and store data.XML is important to know,
and very easy to learn.XML tags are not predefined, user has to define the tags
As: XML is not a replacement for HTML. XML and HTML were designed with different goals:
• XML was designed to transport and store data, with focus on what data
is. • HTML was designed to display data, with focus on how data looks. HTML is about displaying information, while XML is
about carrying information.
As: XML Documents Form a Tree Structure XML documents must contain a root element. This element is parent
of all other elements. The elements in an XML document form a document tree. The tree starts at
the root and branches to the lowest level of the tree. All elements can have sub elements (child elements):
Ex
<root>
<child>
<subchild>.....</subchild>
</child>
</root>
The terms parent, child, and sibling are used to describe the relationships between
elements. Parent elements have children. Children on the same level are called
All elements can have text content and attributes (just like in HTML).
Example:
As: All XML Elements Must Have a Closing Tag XML Tags are Case Sensitive XML Elements Must be Properly Nested
(including) the element's end tag. An element can contain other elements, simple text or a mixture of both. Elements can also
have attributes.