1. 程式人生 > >父元素給定背景,子元素添加內容時背景改變了,怎嘛解決?

父元素給定背景,子元素添加內容時背景改變了,怎嘛解決?

end clas round 問題 add bsp -- class mar

<div class="mui-scroll agree-main">

//用agree-main加了背景色


  <div class="mui-content" style="background-color: transparent!important;">

  //用style="background-color: transparent!important;"可以解決問題


    <div class="mui-content-padded" style="margin:0px !important;"><!--內容頁主體部分start-->


      <h1>hahahahah</h1>


    </div><!--內容頁主體部分end-->
  </div>
</div>

父元素給定背景,子元素添加內容時背景改變了,怎嘛解決?