Myanmar Coder Guide

Course Outline from w3school.com

Saturday, April 24, 2021

CSS background-image

Background-image property က element တစ်ခုရဲ့နောက်ခံအနေနဲ့သုံးဖို့ image ကိုသတ်မှတ်ပါတယ်။ ပုံမှန်အားဖြင့်၊ ပုံသည်ထပ်ခါတလဲလဲဖြစ်နေသောကြောင့်၎င်းသည် element တစ်ခုလုံးကိုဖုံးအုပ်ထားသည်။

Example

စာမျက်နှာတစ်ခု၏နောက်ခံပုံကိုထားပါ။

  1. body{
  2.     background-img:url("paper.gif");
  3. }
Try it Yourself »

Example

This example shows a bad combination of text and background image. The text is hardly readable:

  1. body{
  2.     background-img:url("bgdesert.jpg");
  3. }
Try it Yourself »

မှတ်ချက်။နောက်ခံပုံတစ်ပုံကိုသုံးသောအခါစာသားကိုအနှောင့်အယှက်မပေးသောပုံကိုအသုံးပြုပါ။

နောက်ခံပုံကို <p> element လိုမျိုးတိကျတဲ့ element တွေအတွက်လည်းသတ်မှတ်နိုင်ပါတယ်။

Example

  1. body{
  2.     background-img: url("paper.gif");
  3. }
Try it Yourself »

No comments:

Post a Comment