CSS(YWeb)

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

Change the color of the element with id="para1", to "red".

#para1 {color: red;}

Add an external style sheet with the URL: "mystyle.css".

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

Change the color of all elements with the class "colortext", to "red".

.colortext {color: red;}

Set "background-color: linen" for the page, using an inline style.

<body style="background-color: linen">

Set "paper.gif" as the background image of the page.

<style> body {background-image: url("paper.gif");}

Set the background color for the page to "linen"

<style> body{background-color:linen;}

Set "gradient_bg_vertical.png" as the background image of the page, and repeat it vertically only.

<style> body{background-image:url("gradient_bg_Vertical.png");background-repeat:repeat-y;}

Use the shorthand background property to set background image to "img_tree.png", show it once, in the top right corner.

<style> body{background:url("img_tree.png") no-repeat top right;}

Use the margin property to center align the <h1> element.

<style> h1 { background-color: lightblue; width: 300px;margin:auto;}

Set the left margin of <h1> to "20px".

<style> h1 { background-color: lightblue;margin-left:20px;}

Set all margins for <h1> to "25px".

<style> h1 { background-color: lightblue;margin:25px;}

Use the margin property to set the top and bottom margins for <h1> to "50px", and left and right margins to "25px".

<style> h1 { background-color: lightblue;margin:50px 25px;}

set the background color for <h1> to "lightblue".

<style> h1{background-color:lightblue;]

Set the top padding of <p> to "30px".

<style> p { background-color: lightblue;padding-top:30px;}

Use the padding property to set the top and bottom paddings for <p> to "25px", and left and right paddings to "50px".

<style> p { background-color: lightblue;padding:25px 50px;}

Set all paddings for <p> to "50px".

<style> p { background-color: lightblue;padding:50px;}

Change the 3 border properties, so that they only show the border on the top side.

<style> p { border-top-style: dotted; border-top-width: 4px; border-top-color: red;}

Set a "4px", "dotted" border for <p>.

<style> p{border-style:dotted;border-width:4px;}

With the border property: Set the border for p to "10px", "solid" and "green".

<style> p{border-style:solid;border-width:10px;border-color:green;}

Set "background-color: linen" for the page, using an internal style sheet.

<style> body{background-color: linen;}

Specify that the background image should be shown once, in the top right corner.

body { background-image: url("img_tree.png");background-repeat:no-repeat;background-position: top Right;}

Change the color of all <p> and <h1> elements, to "red". Group the selectors to minimize code.

h1, p {color: red;}

Set the height of <h1> to "100px".

h1{height: 100px;}

Set the border color for <p> to "red".

p { border-style: dotted; border-width: 4px;border-color:red;}

Change the color of all <p> elements to "red".

p {color: red;}


Set pelajaran terkait

Lssn 13 Ch 11 How Genes are Controlled (Finals)

View Set

Chapter 7: Working with the BASH Shell

View Set

OCE CHAPTER 14 (EXAM 5: 12, 14, 15)

View Set

Rights Interest & Estates: Ownership

View Set

Module 2 Chapter 32 Care of Critically Ill Pt. With Respiratory Problems

View Set

Honan, Chapter 28: Nursing Management: Patients With Urinary Disorders

View Set