PrepAway - Latest Free Exam Questions & Answers

Which value should you use?

You are developing an HTML5 page. The page includes the following code.

The inner paragraph must be exactly 15 pixels from the top left corner of the outer
paragraph. You set the left style for the inner paragraph to the appropriate value.
You need to set the position property of the inner paragraph.
Which value should you use?

PrepAway - Latest Free Exam Questions & Answers

A.
absolute

B.
static

C.
fixed

D.
relative

Explanation:

http://www.w3schools.com/cssref/pr_class_position.asp

4 Comments on “Which value should you use?

  1. colins says:

    A is correct.
    ‘relative’ positioning is relative to normal position of element
    ‘absolute’ positioning is relative to first positioned ancesor

    outer paragraph is a first positioned ancesor (position is not static)




    0



    0

Leave a Reply