1.

Body { background-image: url(“learn.gif”); background-repeat: repeat-x}In reference with the above CSS code, explain the usage of background-repeat property. Also mention the different values that can be used for background-repeat.

Answer»

With reference to the above CSS code the inserted background image learn.gif will repeat horizontally on the browser screen.

The four different values for background-repeat are as follows:

Value Description 
background-repeat: repeat-x : The image is repeated horizontally. 
background-repeat: repeat-y :The image is repeated vertically.
background-repeat: repeat :The image is repeated both horizontally and vertically
background-repeat: no-repeat :The image is not repeated



Discussion

No Comment Found

Related InterviewSolutions