Long Test #2: CSS And Frames

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Teacher Rizs
T
Teacher Rizs
Community Contributor
Quizzes Created: 1 | Total Attempts: 368
Questions: 35 | Attempts: 368

SettingsSettingsSettings
Long Test #2: CSS And Frames - Quiz

Good luck swithartz! Kung Hei Fat Choi! :)


Questions and Answers
  • 1. 

    What does CSS stand for?

    • A.

      Computer Style Sheets

    • B.

      Creative Style Sheets

    • C.

      Cascading Style Sheets

    Correct Answer
    C. Cascading Style Sheets
    Explanation
    CSS stands for Cascading Style Sheets. It is a stylesheet language used for describing the look and formatting of a document written in HTML. CSS allows web designers to separate the content of a webpage from its presentation, making it easier to control the layout, colors, fonts, and other visual aspects of a website. The term "cascading" refers to the way CSS rules can be applied in a hierarchical manner, allowing for a consistent and organized styling across multiple webpages.

    Rate this question:

  • 2. 

    What is the correct HTML for referring to an external style sheets

    • A.

      <link rel=stylesheet type=text/css href=mystyle.css>

    • B.

      Mystyle.css

    • C.

      <style>

    Correct Answer
    A. <link rel=stylesheet type=text/css href=mystyle.css>
    Explanation
    This is the correct HTML for referring to an external style sheet. The element is used to link an external resource to the HTML document, in this case, a style sheet. The "rel" attribute specifies the relationship between the HTML document and the linked resource, in this case, "stylesheet" indicates that the linked resource is a style sheet. The "type" attribute specifies the type of the linked resource, in this case, "text/css" indicates that the linked resource is a CSS file. The "href" attribute specifies the URL or file path of the linked resource, in this case, "mystyle.css" is the file name of the external style sheet.

    Rate this question:

  • 3. 

    Where in an HTML document is the correct place to refer to an external style sheet?

    • A.

      In the <body> section

    • B.

      At the end of the document

    • C.

      In the <head> section

    Correct Answer
    C. In the <head> section
    Explanation
    The correct place to refer to an external style sheet in an HTML document is in the section. This is where the document's metadata, such as title and character encoding, is typically placed. By linking the external style sheet in the section, it allows the browser to load and apply the styles before rendering the content in the section. This ensures that the styles are applied consistently across the entire document.

    Rate this question:

  • 4. 

    Which HTML tag is used to define an internal style sheet?

    • A.

      <script>

    • B.

      <css>

    • C.

      <style>

    Correct Answer
    C. <style>
    Explanation
    The tag is used to define an internal style sheet in HTML. This tag is placed within the section of the HTML document and is used to specify the CSS rules for styling the elements within the document. By using the tag, the CSS code can be written directly within the HTML file, making it easier to manage and maintain the styles for the webpage.

    Rate this question:

  • 5. 

    Which HTML attribute is used to define inline styles?

    • A.

      Font

    • B.

      Class

    • C.

      Style

    Correct Answer
    C. Style
    Explanation
    The HTML attribute used to define inline styles is "style". This attribute allows you to apply specific styles directly to an HTML element, such as setting the font color, background color, or font size. By using the "style" attribute, you can customize the appearance of individual elements without having to create a separate CSS file or use external stylesheets.

    Rate this question:

  • 6. 

    Which is the correct CSS syntax?

    • A.

      Body {color: black;}

    • B.

      Body:color=black;

    • C.

      {body;color:black;}

    Correct Answer
    A. Body {color: black;}
    Explanation
    The correct CSS syntax is "body {color: black;}". In CSS, selectors are used to target specific HTML elements, and in this case, the selector "body" is used to target the body element. The curly brackets {} are used to enclose the declaration block, which contains the property "color" and its corresponding value "black". This syntax follows the standard CSS syntax conventions.

    Rate this question:

  • 7. 

    Which property is used to change the background color?

    • A.

      Background-color

    • B.

      Color

    • C.

      Bgcolor

    Correct Answer
    A. Background-color
    Explanation
    The property used to change the background color is "background-color". This property allows you to specify a color for the background of an element. It can be set to a specific color value or even to transparent. By using this property, you can easily customize the background color of an element to match your design preferences.

    Rate this question:

  • 8. 

    How do you add a background color for all <h1> elements?

    • A.

      H1 {background-color:#FFFFFF;}

    • B.

      All.h1 {background-color:#FFFFFF;}

    • C.

      23l {background-color:#FFFFFF;}

    Correct Answer
    A. H1 {background-color:#FFFFFF;}
    Explanation
    The correct answer is h1 {background-color:#FFFFFF;}. This CSS code targets all <h1> elements and sets the background color to white (#FFFFFF).

    Rate this question:

  • 9. 

    Which CSS property is used to change the text color of an element?

    • A.

      Text-color

    • B.

      Color

    • C.

      Fgcolor

    Correct Answer
    B. Color
    Explanation
    The CSS property "color" is used to change the text color of an element.

    Rate this question:

  • 10. 

    Which CSS property controls the text size?

    • A.

      Font-size

    • B.

      Text-size

    • C.

      Font-style

    Correct Answer
    A. Font-size
    Explanation
    The CSS property "font-size" controls the size of the text. It allows you to specify the desired size of the font in pixels, ems, or other units. By using this property, you can make the text appear larger or smaller on the webpage, depending on your requirements.

    Rate this question:

  • 11. 

    What is the correct CSS syntax for making all the <p> elements bold?

    • A.

      <p style="text-size:bold;">

    • B.

      P {font-weight:bold;}

    • C.

      P {text-size:bold;}

    Correct Answer
    B. P {font-weight:bold;}
    Explanation
    The correct CSS syntax for making all the elements bold is "p {font-weight:bold;}". This CSS rule targets all elements and sets the font-weight property to bold, which makes the text appear in a bold font weight.

    Rate this question:

  • 12. 

    Which property is used to change the font of an element?

    • A.

      Font-weight

    • B.

      Font-family

    • C.

      Font-style

    Correct Answer
    B. Font-family
    Explanation
    The property used to change the font of an element is font-family. This property allows you to specify the typeface or font that should be applied to the text content of the element. By specifying different font families, you can change the appearance of the text to match the desired style or design.

    Rate this question:

  • 13. 

    How do you make the text bold?

    • A.

      Font:bold;

    • B.

      Font-weight:bold;

    • C.

      Style-bold

    Correct Answer
    B. Font-weight:bold;
    Explanation
    The correct answer is "font-weight:bold;". This CSS property is used to make the text bold. The "font-weight" property specifies the weight or thickness of the font. By setting it to "bold", the text will appear in a bold font style.

    Rate this question:

  • 14. 

    How do you make a list that lists its items with squares?

    • A.

      List: square;

    • B.

      List-type: square;

    • C.

      List-style-type: square;

    Correct Answer
    C. List-style-type: square;
    Explanation
    The correct answer is "list-style-type: square;" because this CSS property is used to specify the style of the list item marker. In this case, it sets the marker to be a square shape. The other options, "list: square;" and "list-type: square;", are not valid CSS properties for creating a list with square markers.

    Rate this question:

  • 15. 

    How do you select an element with id "demo"?

    • A.

      Demo

    • B.

      *demo

    • C.

      #demo

    Correct Answer
    C. #demo
    Explanation
    To select an element with the id "demo", you can use the CSS selector "#demo". The "#" symbol is used to target an element with a specific id, and in this case, it is targeting the element with the id "demo".

    Rate this question:

  • 16. 

    How do you display hyperlinks without an underline?

    • A.

      A {text-decoration:none;}

    • B.

       a {underline:none;}

    • C.

      A {text-decoration:no-underline;}

    Correct Answer
    A. A {text-decoration:none;}
    Explanation
    The correct answer is "a {text-decoration:none;}". By using this CSS code, the hyperlinks will be displayed without an underline. The "text-decoration" property is used to control the decoration of text, such as underline, overline, or line-through. Setting it to "none" removes any decoration from the text, effectively removing the underline from the hyperlink.

    Rate this question:

  • 17. 

    Which property is used to change the left margin of an element?

    • A.

       margin-left

    • B.

      Padding-left

    • C.

      Indent

    Correct Answer
    A.  margin-left
    Explanation
    The property used to change the left margin of an element is "margin-left". This property allows you to adjust the space between the left edge of the element and its neighboring elements. By specifying a value for "margin-left", you can create space on the left side of the element, pushing it away from other elements.

    Rate this question:

  • 18. 

    How do you group selectors?

    • A.

      Separate each selector with a space

    • B.

      Separate each selector with a plus sign

    • C.

      Separate each selector with a comma

    Correct Answer
    C. Separate each selector with a comma
    Explanation
    To group selectors in CSS, you need to separate each selector with a comma. This allows you to apply the same styles to multiple elements at once. For example, if you want to apply a specific style to all paragraphs and headings, you can group them together by separating the selectors with a comma like this: "p, h1, h2, h3". This way, the defined styles will be applied to all paragraphs and headings in the document.

    Rate this question:

  • 19. 

    What is the correct HTML for adding a background color?

    • A.

      <background>yellow</background>

    • B.

      <body style="background-color:yellow;">

    • C.

      <body bg="yellow">

    Correct Answer
    B. <body style="background-color:yellow;">
    Explanation
    The correct HTML for adding a background color is "". This is because the "style" attribute is used to define the inline CSS properties for an element, and "background-color" is the CSS property that sets the background color of an element. In this case, the background color is set to yellow.

    Rate this question:

  • 20. 

    What is the correct HTML for creating a hyperlink?

    • A.

      <a href=longtest2.html>Long Test #2 </a>

    • B.

      <a longtest2.html>Long Test #2 </a>

    • C.

      <a href=longtest2.html>Long Test #2 </href>

    Correct Answer
    A. <a href=longtest2.html>Long Test #2 </a>
    Explanation
    The correct HTML for creating a hyperlink is "Long Test #2 ". This is because the element is used to create a hyperlink, and the href attribute specifies the URL of the page that the link goes to. The text between the opening and closing tags is the visible text of the link.

    Rate this question:

  • 21. 

    Which of these elements are all <table> elements?

    • A.

      <table><head><tfoot>

    • B.

      <table><tr><tt>

    • C.

      <table><tr><td>

    Correct Answer
    C. <table><tr><td>
    Explanation
    The elements , , and are all elements. The element is used to create a table, the element represents a row in the table, and the element represents a cell in the table. Therefore, all three elements mentioned in the answer are valid elements.

    Rate this question:

  • 22. 

    What is the correct HTML for making a checkbox?

    • A.

      <input type="check">

    • B.

      <checkbox>

    • C.

      <input type="checkbox">

    Correct Answer
    C. <input type="checkbox">
    Explanation
    The correct HTML for making a checkbox is . This input element with the type attribute set to "checkbox" creates a checkbox that allows users to select or deselect an option.

    Rate this question:

  • 23. 

    What is the correct HTML for making a text input field?

    • A.

      <textfield>

    • B.

      <input type="textfield">

    • C.

      <input type="text">

    Correct Answer
    C. <input type="text">
    Explanation
    The correct HTML for making a text input field is "". This is because the "" tag is used to create an input field, and the "type" attribute specifies the type of input field, in this case, "text" for a text input field.

    Rate this question:

  • 24. 

    What is the correct HTML for making a drop-down list?

    • A.

      <input type="list">

    • B.

      <select>

    • C.

      <input type="dropdown">

    Correct Answer
    B. <select>
    Explanation
    The correct HTML for making a drop-down list is . This tag is used to create a drop-down list in HTML.

    Rate this question:

  • 25. 

    What is the correct HTML for inserting a background image?

    • A.

      <body style="background-image:url(background.gif)">

    • B.

      <body bg="background.gif">

    • C.

      <background img="background.gif">

    Correct Answer
    A. <body style="background-image:url(background.gif)">
    Explanation
    The correct HTML for inserting a background image is . This code uses the style attribute to set the background image of the body element to "background.gif".

    Rate this question:

  • 26. 

    The <____________> tag defines how to divide the window into frames

    • A.

      Frame

    • B.

      Frames

    • C.

      Frameset

    Correct Answer
    C. Frameset
    Explanation
    The correct answer is "frameset". The frameset tag is used to define how to divide the window into frames. Frames allow for the display of multiple web pages within a single browser window. By using the frameset tag, web developers can specify the layout of these frames, such as their size, position, and arrangement within the window.

    Rate this question:

  • 27. 

    With frames, you can display more than one HTML document in the same browser window.

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    Frames in HTML allow multiple HTML documents to be displayed within the same browser window. By dividing the window into separate sections or frames, each frame can load and display a different HTML document. This is useful for creating websites with multiple sections or displaying content from different sources simultaneously. Therefore, the correct answer is true.

    Rate this question:

  • 28. 

    Each HTML document is called a frame, and each frame is dependent of the others

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    Frames in HTML are used to divide a web page into multiple sections, each containing a separate HTML document. These frames are interdependent, meaning that changes in one frame can affect the content displayed in other frames. Therefore, the statement that each HTML document is called a frame and each frame is dependent on the others is true.

    Rate this question:

  • 29. 

    Each frameset defines a set of height or width

    • A.

      True

    • B.

      False

    Correct Answer
    B. False
    Explanation
    Each frameset does not define a set of height or width. Framesets are used to divide a web page into multiple sections, each containing a separate HTML document. The height and width of each frame within a frameset are defined individually using the "rows" and "cols" attributes.

    Rate this question:

  • 30. 

    Is this syntax correct? <html> <body> <frameset cols=“30%,40%,30%”>   <frame src = “frame a.html”>   <frame src = “frame b.html”>   <frame src = “frame c.html”> </frameset> </html>

    • A.

      True

    • B.

      False

    Correct Answer
    B. False
    Explanation
    The syntax is correct. The code is using HTML tags to create a frameset with three columns, each containing a frame with a specific source file. The syntax for specifying the source file in the "src" attribute is also correct. Therefore, the correct answer should be "True" rather than "False".

    Rate this question:

  • 31. 

    Is this syntax correct?   <html> <frames rows=“30%,40%,30%”>   <frame src = “frame a.html”>   <frame src = “frame b.html”>   <frame src = “frame c.html”> </frames> </html>

    • A.

      True

    • B.

      False

    Correct Answer
    B. False
    Explanation
    The syntax is correct. The code is using the correct HTML tags for creating frames within a webpage. The "frames" tag is used to define the layout of the frames, and each "frame" tag is used to specify the source file for each frame. Therefore, the correct answer should be True, not False.

    Rate this question:

  • 32. 

    The <frameset> element specifies HOW MANY columns or rows there will be in the frameset, and HOW MUCH percentage/pixels of space will occupy each of them.

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    The element is used to define the structure of a frameset, which can contain multiple columns or rows. It specifies the number of columns or rows that will be present in the frameset, as well as the percentage or pixel value of space that each column or row will occupy. This allows for the layout of the frameset to be customized according to the desired proportions. Therefore, the given statement that the element specifies how many columns or rows there will be in the frameset, and how much percentage/pixels of space will occupy each of them, is true.

    Rate this question:

  • 33. 

    The cols attribute specifies the number and size of rows in a frameset

    • A.

      True

    • B.

      False

    Correct Answer
    B. False
  • 34. 

    Each <frame> element can hold a separate document.

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    The statement is true because in HTML, the element is used to divide a web page into multiple sections, each of which can display a separate document. This allows for the creation of framesets, where each frame can load a different webpage or HTML document. Therefore, each element can indeed hold a separate document.

    Rate this question:

  • 35. 

    The attribute row specifies the number and size of rows in a frameset

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    The attribute "row" in a frameset specifies the number and size of rows in the frameset. This means that by using the "row" attribute, we can determine how many rows are present in the frameset and also set the size of each row.

    Rate this question:

Quiz Review Timeline +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Mar 21, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Feb 03, 2019
    Quiz Created by
    Teacher Rizs
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.