CSS captures background images

Source: Internet
Author: User

Background five important attributes

Background-color: Specifies the color of the fill background.
Background-image: references a picture as a background.
Background-position: Specifies the position of the element background picture.
Background-repeat: Decide whether to repeat the background picture.
Background-attachment: Determines whether the background graph scrolls with the page.

. MYBG {
width:800px;/* Capture the width of the picture */
height:800px;/* the height of the captured image */
Background-image:url (repair101.jpg);/* Add background picture */
background-position:400px 400px;/* location from background image-X, y coordinates */
}

. MYBG {
width:a;/* Capture the width of the picture */
height:b;/* the height of the captured image */
Background-image:url (repair101.jpg);/* Add background picture */
Background-position:c d;/* the position captured from the background image-X, y coordinates, C, D as percent */
}

x = A+c; y = b*d;

CSS captures background images

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.