Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Login

Register Now

Welcome to All Test Answers

Chapter 1- HTML and the Modern Web

Download  file with the answers

Not a member!

Create a FREE account here to get access and download this file with answers


 

Chapter 1: HTML and the Modern Web

TRUE/FALSE

1. The W3C was founded before HTML was first formalized.

2. The various committees that make up the W3C look to expand and set standards for the many new Web technologies that have emerged.

3. XML does not allow you to create your own elements.

4. It is best practice to use all uppercase characters for element and attribute names when writing HTML5.

5. HTML is a What You See Is What You Get (WYSIWYG) layout tool.

6. Most recent HTML authoring tools offer syntax validation and code conversion.

7. A page that you create in an editing interface will always look exactly the same in every browser.

8. Following the W3C standards does not mean that your site has to be visually uninteresting, although you may have to sacrifice the latest multimedia enhancements.

9. Standardizing coding practices helps clean up most common coding errors.

10. Migrating from HTML to HTML5 in an existing site should be done as quickly as possible.

 

MULTIPLE CHOICE

1. The ____ element tag indicates that the text is a top-level heading.

 

2. HTML elements should be used properly to describe each section of the document based on the ____ structure of the document.
a. programming c. coding
b. design d. logical

3. Every browser interprets HTML in its own way, based on its ____.
a. compiler c. rendering engine
b. translator d. interpreter

4. ____ lets you control the presentation characteristics of an entire Web site with a single style sheet document.
a. SGML c. CSS
b. WYSIWYG d. HTML

5. A ____ is a set of rules that describes the display characteristics of a document.
a. template sheet c. template
b. style sheet d. guide

6. Tim Berners-Lee first proposed HTML at the European Laboratory for Particle Physics (CERN) in ____.
a. 1984 c. 1989
b. 1987 d. 1991

7. The need for new markup languages and standards to address new demands is handled by the ____.
a. WC c. W2C
b. W1C d. W3C

8. The W3C released version 4.01 of ____ in 1999.
a. XHTML c. CSS
b. HTML d. XML

9. ____ follows the markup rules of ____.
a. XML; XHTML c. HTML; XML
b. XHTML; XML d. HTML; XHTML

10. In XHTML, empty elements are marked with a(n) ____ slash.
a. cancel element c. closing slash
b. end tag d. null string

11. Which of the following is a valid XHTML statement?
a.

This is the first paragraph.

b.

This is the first paragraph.
c.

This is the first paragraph.
d.

This is the first paragraph.

12. The stricter syntax rules of HTML5 are consistent with ____ syntax.
a. CSS c. JSP
b. WYSIWYG d. XHTML

13. In a professional Web development environment, it is best practice to code using syntax that follows the basic ____ syntax rules.
a. CSS c. XML
b. HTML d. ASP

14. When one source of content is maintained but disseminated to different users or devices, it is called ____.
a. single-sourcing c. styling
b. templating d. coding

15. HTML5 is no longer based on ____.
a. SGML c. CSS
b. WYSIWYG d. WCC

16. A ____ document is one that adheres to the syntax rules of the language.
a. rule-adhering c. proper
b. standardized d. well-formed

17. Which of the following is the most compatible?
a.

Here is some text

b. <”p” class=“copy”>Here is some text
c.

Here is some text

d.

Here is some text

18. The ____ element is the root or parent element of all content sections, making it a sectioning root.

19. Which of the following is a heading element?

20. Which of the following elements is included in phrasing content?21. Which of the following is a new element of HTML5 that lets scripting applications dynamically render graphics, animations or other visual images?22. The HTML5 element

is used to contain ____.
a. the primary page content
b. additional content such as a quote or sidebar
c. the page header content
d. images for article content23. Coding with standards and respecting the W3C mandate to separate ____ from ____makes your content more accessible and portable to different devices and destinations.
a. content structure, presentation information
b. images, text
c. colors, fonts
d. images, content24. What is one of the most common mistakes that could make your code invalid?
a. Declaring a doctype c. Quoting attributes
b. Missing closing tags d. Nesting tags25. What is the first step you need to take to migrate from HTML to HTML5?
a. Evaluate existing display information c. Evaluate existing code
b. Create coding conventions d. Start using CSSCOMPLETION1. Once you are familiar with HTML syntax, you will find that one of the best ways to learn new coding techniques is to find a Web page you like and view the ____________________.

ANS: source code

PTS: 1 REF: 4

2. The most engaging aspect of browsing the World Wide Web is the linking of information on related topics using ____________________, a nonlinear way of organizing information.

ANS: hypertext

PTS: 1 REF: 8

3. The ____________________ sets standards for HTML and provides an open, nonproprietary forum for industry and academic representatives.

ANS:
W3C
World Wide Web Consortium

W3C (World Wide Web Consortium)
World Wide Web Consortium (W3C)

PTS: 1 REF: 10

4. ____________________ elements are those that the W3C has identified as obsolete and consequently will not be included in future releases of HTML.

ANS: Deprecated

PTS: 1 REF: 11

5. You can nest XHTML tags, but they must not ____________________.

ANS: overlap

PTS: 1 REF: 19

6. All attribute values in XHTML must be contained within ____________________.

ANS:
quotes
quotation marks

PTS: 1 REF: 19|21

7. Information about the document itself, such as how to present the document, or what other documents are related to the current one, such as style sheets, is known as ____________________.

ANS: metadata

PTS: 1 REF: 21

8. ____________________ is descriptive markup that identifies the intended use of document sections.

ANS: Semantic markup

PTS: 1 REF: 31

9. ____________________ allows HTML authors to write style rules that affect the display of Web pages.

ANS:
Cascading Style Sheets
CSS
Cascading Style Sheets (CSS)
CSS (Cascading Style Sheets)

PTS: 1 REF: 34

10. A(n) ____________________ is a structured language that lets you identify common elements of a document such as headings, paragraphs, and lists.

ANS: markup language

PTS: 1 REF: 2|35

ESSAY

1. Define HTML, and describe its structure and role in Web design.

ANS:
HTML is a markup language, a structured language that lets you identify common sections of a Web page such as headings, paragraphs, and lists with markup tags that define each section. For example, the

element in the following code indicates that the text is a first-level heading:

What is HTML?

Web pages are simply text documents that use HTML to tell the browser how to display each document section.

An HTML file includes the text that the user sees in the browser, contained within HTML markup elements the user cannot see that identify document sections and elements.

The HTML code is interpreted by the browser to create the displayed results. HTML is an application of SGML, a standard system for specifying document structure using markup tags.

PTS: 1 REF: 2-4

2. What are Cascading Style Sheets? Why are they useful?

ANS:
To add presentation information to Web pages, Web designers use a style language called Cascading Style Sheets (CSS). With CSS you can display information for different devices, lay out page designs, and control typography, color, and many other presentation characteristics.

Style elements such as were introduced by browser developers to help Web designers bypass the design limitations of HTML. Using elements such as to embed style information within structure limits the cross-platform compatibility of the content. A style sheet is a set of style rules that describes the display characteristics of a document. With style sheets, the presentation properties are separate from the content. This accommodates the variety of devices and users that browse the Web.

CSS lets you control the presentation characteristics of an entire Web site with a single style sheet document. For example, assume you want all of your

headings to appear green and centered everywhere on your Web site. Prior to CSS you might have included the following code for every instance of an

element:

 

Some Heading Text

 

Using a CSS rule, you can express the same style as follows:

h1 {color: green; text-align: center;}

You can place this rule in an external style sheet and then link every page on your site to that style sheet; the single rule controls every

element in your Web site. Later, if you want to change the

color to red, you simply revise the style sheet rule to change every page on your site.

PTS: 1 REF: 5-8

3. Describe the two syntaxes HTML5 offers and explain the reasons why you may choose to use one over the other.

ANS:
HTML5 offers two syntaxes. One is based on HTML syntax, and the other on stricter XML syntax rules, which makes it compatible with XHTML.

The HTML version of HTML5 is more relaxed and allows authors to use shortcuts in their code. Elements do not always have to be closed and the class attributes do not require quotes around their content values. This more relaxed version of HTML5 is backwards compatible with HTML 4.01. This syntax is appropriate for anyone building a noncommercial Web site.

The stricter syntax rules of HTML5 are consistent with XHTML syntax. XML syntax rules are applied. All elements require closing tags and class attributes require quotes around their content value. In a professional Web development environment it is best practice to code with this syntax. Using this syntax, the code you create for Web content can have multiple purposes and potentially be used in a variety of display and application environments.

PTS: 1 REF: 16-17

4. List the six basic rules needed to create syntactically correct HTML5 code and briefly describe each one.

ANS:
1. Documents must be well formed: A well-formed document is one that adheres to the syntax rules.

2. All tags must nest properly and not overlap: You can nest HTML elements, but they must not overlap. Each set of opening and closing tags must completely contain any elements that are nested within the set.

3. Use all lowercase for element names: Even though HTML5 allows uppercase and lowercase element names, it is considered good coding practice to always use lowercase. Use all lowercase characters for element and attribute names when writing your code, this will ensure that your code can be XHTML compatible if it needs to be used in some type of content management or application processing environment.

4. Always use closing tags: Although in the looser HTML5 syntax certain elements such as the

elements are allowed optional closing tags, it is a much better practice to always close all elements.

5. Empty elements are marked with a closing slash: Empty elements must be marked “empty” by a slash ( / ) in the single tag.

6. Attribute values must be contained in quotation marks: Although in the looser HTML5 syntax, attribute values do not have to be quoted, your code is more compatible when you always contain all attribute values within quotes.

PTS: 1 REF: 19-21

5. What are the five steps involved in migrating from HTML to HTML5? Briefly describe each step.

ANS:
1. Evaluate existing code: Check for basic compliance with XHTML syntax rules. Are closing tags included? Are all tags lowercase? Are attributes quoted? How much cleanup work is necessary to make the code well formed? Most of this work can be automated in the various HTML editing programs.

2. Evaluate existing presentation information: How much of your code includes obsolete elements such as and obsolete attributes such as “bgcolor,” “face,” and “size”? On many sites, this information can make up as much as 50 percent of the existing code. Start thinking about how you can express these characteristics in CSS.

3. Create coding conventions: Create coding conventions and follow them throughout the site. Make sure that new content added to the site follows the new coding and CSS standards.The more you standardize, the easier your maintenance chores become.

4. Start using CSS: Start by building simple style sheets that express basic characteristics such as page colors, font family, and font size. Consider using more advanced CSS options such as classes that allow you to name and standardize the various styles for your site. As you build style rules, start to remove the existing display information in the site.

5. Test for backward compatibility: Remember to test in older browsers to make sure that your content is legible and readable. Test carefully with your CSS style rules to make sure that they are supported in older browsers.

PTS: 1 REF: 33

About

Leave a reply

Captcha Click on image to update the captcha .

error: Content is protected !!