English 中文(简体)
保护次Div 背景
原标题:Protect Sub-Div Background
  • 时间:2012-05-01 08:07:36
  •  标签:
  • html
  • css

我ve一(四)小 d,一想改变上半人的背景,保持其背景不变。

是否有办法保护小孩的亲子财产?

P.S:我可以人工改变孩子的亲子关系。 这是因为:

td.name:before {
    clip: rect(0px, 490px, 20px, 0px);
    white-space: nowrap;
    content:
    position: absolute;
    z-index: -1;
}

内部和当一页改动时,就会失去“联系”。

最佳回答

儿童四分五裂令造成了这一问题。 改变“z-index”价值,并做了。

问题回答

如果明确确定,孩子的背景就会受到父母背景的影响。 在下面的例子中,你可以看到,我们明确为这两个要素制定背景规则。 因此,父母的背景不会影响儿童的背景。

彩色财产就属于这种情况。 由于我们为父母而不是孩子确定,孩子从父母那里继承其肤色。

<style>
  #parent {
    background: red;
    color: white;
  }
  #child {
    background: green;
  }
</style>
<div id="parent">
  <p>I am white text</p>
  <div id="child">
    <p>I am also white text</p>
  </div>
</div>

Demo:





相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签