Computer Knowledge

Markup and Web Languages

1,492 Questions

Test your understanding of HTML tags, XML structures, and web page creation technologies. The questions cover elements like CSS styling, parsing documents, and defining web attributes. This section is essential for candidates appearing for computer proficiency tests in various competitive exams.

HTML tags and attributesXML document parsingCSS styling levelsWeb page creation basicsBrowser compatibility

Markup and Web Languages Questions

Multiple choice html
  1. Body

  2. Head

  3. Division

  4. Table

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

To answer this question, the user needs to know the basic structure of an HTML document. The HTML document consists of two main parts, the head and the body. The head section contains metadata, such as the page title, while the body section contains the visible content of the webpage. Therefore, the correct answer is:

The Answer is: B, Head.

Option A, Body, is incorrect because the body section contains the visible content of the webpage, such as text, images, videos, etc.

Option C, Division, is incorrect because the division tag

is a container tag that is used to group related elements together.

Option D, Table, is incorrect because the table tag is used to create a table on a webpage.

Multiple choice javascript
Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The window.open() method opens a new browser window. It takes the URL as the first argument and the window name as the second. Option B correctly shows this syntax: window.open('url', 'windowname'). Options A, C, and D use incorrect methods or syntax that don't exist in JavaScript.

Multiple choice javascript
  1. window.status = "put your message here"

  2. statusbar = "put your message here"

  3. status("put your message here")

  4. window.status("put your message here")

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The browser's status bar can be accessed via window.status property. Option A correctly assigns a string to window.status. Option B uses an undefined 'statusbar' variable. Option C calls a non-existent status() function. Option D incorrectly treats status as a function rather than a property.

Multiple choice javascript
  1. window.location.href

  2. document.href

  3. java.redirect.url

  4. link.redirect.href

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

To redirect a visitor to another page using JavaScript, you can use the window.location.href property. This property sets or returns the entire URL of the current page, including the protocol, host name, path, and the file name of the current page. By assigning a new URL to this property, you can redirect the user to a new page.

Option A is correct: window.location.href

Option B is incorrect because there's no document.href property.

Option C is incorrect because there's no java.redirect.url property.

Option D is incorrect because there's no link.redirect.href property.

Therefore, the correct answer is:

The Answer is: A

Multiple choice javascript
  1. Platform dependent

  2. Platform linkage

  3. Platform independent

  4. Platform binding

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

JavaScript is platform-independent and runs in any browser or environment that implements the JavaScript engine. The same code executes consistently across Windows, Mac, Linux, and other operating systems without modification.

Multiple choice javascript
  1. this is a good practice

  2. this is REQUIRED

  3. this ensures browser compatibility

  4. this ensures OS compatibility

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

While the 'window' object is the global scope in browser-based JavaScript and its properties can be accessed without the prefix, explicitly including it is considered good practice for code clarity and avoiding naming collisions. It is not strictly required for compatibility or execution.

Multiple choice web-design
  1. It is a new hybrid technology that is different from both XML and HTML.

  2. You can't use it to create Web pages.

  3. It is a reformulation of HTML in XML.

  4. It has totally replaced HTML as the tool for building Web pages.

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

To solve this question, the user needs to have a basic understanding of web development and markup languages.

Now, let's go through each option and explain why it is right or wrong:

A. It is a new hybrid technology that is different from both XML and HTML. - This option is incorrect. XHTML stands for "Extensible Hypertext Markup Language", and it is a markup language that is based on XML. XHTML combines the syntax of HTML with the strictness of XML.

B. You can't use it to create Web pages. - This option is incorrect. XHTML is used to create web pages just like HTML.

C. It is a reformulation of HTML in XML. - This option is correct. XHTML is a reformulation of HTML in XML, which makes it easier for web developers to create valid and well-formed web pages.

D. It has totally replaced HTML as the tool for building Web pages. - This option is incorrect. Although XHTML has some advantages over HTML, it has not completely replaced it. HTML is still widely used for building web pages.

Therefore, the correct answer is:

The answer is: C

Multiple choice web-design
  1. DHTML

  2. SGML

  3. CSS

  4. XHTML

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

CSS (Cascading Style Sheets) is the technology for handling multiple overlapping styles through specificity, inheritance, and cascade rules. Inline styles are part of CSS. While the question's phrasing is awkward (it should say 'inline styles are part of'), CSS is clearly the intended answer over DHTML, SGML, or XHTML.

Multiple choice web-design
  1. you cannot do this

  2. use the ASK attribute

  3. use the MESSAGE attribute

  4. use the PROMPT attribute

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The ISINDEX tag (a deprecated HTML element for simple search queries) used the PROMPT attribute to override the default prompt text that appeared before the input field. There is no ASK or MESSAGE attribute in the HTML specification for ISINDEX, and it was possible to customize the prompt.

Multiple choice web-design
  1. Absolute URL (http://www.site.com/directory/page.htm)

  2. Relative URL (../directory/page.htm)

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

Relative URLs are preferred for internal linking because they make the website portable. If the domain name changes or the site is moved to a different directory level, the links remain functional. Absolute URLs are rigid and harder to maintain for internal site structures.

Multiple choice xhtml
  1. X-function of HTML

  2. Ex Hyper Text Markup Language

  3. Extensible Hypertext Markup Language

  4. Extensible Hype Manditory Learning

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

XHTML stands for Extensible Hypertext Markup Language. It is a stricter, XML-based version of HTML that requires well-formed syntax and proper nesting of elements.

Multiple choice xhtml
  1. A method tied to an object

  2. A Detrimental Transitional Development

  3. The Document Type Declaration

  4. The Difinitive Type Definition

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

DTD stands for Document Type Declaration. It defines the structure and legal elements of an XML or XHTML document, telling parsers which tags and attributes are valid.

Multiple choice xhtml
  1. XHTML and SGML are both subsets of HTML

  2. XHTML is a subset of SGML

  3. SGML is a subset of XHTML

  4. SGML is a simplified version of XHTML

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

XHTML is defined as a subset of SGML (Standard Generalized Markup Language), just as HTML is. SGML is the parent meta-language from which both HTML and XHTML derive their rules. Option A is incorrect because HTML and XHTML are subsets of SGML, not the reverse.