开发者

Design all 'pre' tags inside a div in css

How do i style the width of all "pre" tags inside a div with some id ? I can't put the "class" attribute inside the 开发者_开发百科pre tag, becouse the pre tag is written by a function that i have no access to it.


CSS

#parent {} /* add style to the parent element */
#parent pre {color: red} /* to the pre */

HTML

<div id="parent">
  <pre>aaa</pre>
</div>


like this???

div#id pre { styles here }


Use this selector div#someId pre...............

div#someId pre
{
    width: ...
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜