DIV CSSÍøÒ³²¼¾Ö£º×îС¸ß¶È£¨min height£©µÄÃîÓÃ
×îС¸ß¶È¿ÉÒÔÉ趨һ¸öBOXµÄ×îС¸ß¶È£¬µ±ÆäÄÚÈݽÏÉÙʱʱ£¬Ò²Äܱ£³ÖBOXµÄ¸ß¶ÈΪһ¶¨£¬³¬³ö¾Í×Ô¶¯ÏòÏÂÑÓÉ죬µ«µ½Ä¿Ç°ÎªÖ¹£¬Ö»ÓÐ
Opera ºÍ Mozilla Ö§³Ö£¬IE7¿ªÊ¼Ò²Ö§³ÖÁË£¬µ«IE7´¦ÓÚ²âÊԽ׶Σ¬µÈÕýʽ°æ·¢²¼µ½ÆÕ¼°ÐèÒ»¶ÎÒ²Ðí±È½Ï³¤µÄʱ¼ä£¬³ý·ÇMS°ÑËüÀ¦°óÔÚij¸ö
²Ù×÷ϵͳÉÏ£¬ÈçºÎÔÚÏÖÓлù´¡ÉÏ£¨IE6 80-90%£©£¬ºÏÀí¡¢ÃîÓÃ×îС¸ß¶ÈÁË£¿
¼Ù¶¨Óжþ¸öBOX£¬ÎÒÃÇÐèÒªËüµÄ×îС¸ß¶ÈΪ150PX¡£
CSS
div.box1,div.box2{
width: 300px;
min-height: 150px;
background: #EEE;
float: left;
margin-right: 20px;
}
xhtml
<div>IEÖÐû±£³Ö×îС¸ß¶ÈΪ150px</div>
<div>
×îС¸ß¶È¿ÉÒÔÉ趨һ¸öBOXµÄ×îС¸ß¶È£¬ µ±ÆäÄÚÈݽÏÉÙʱʱ£¬Ò²Äܱ£³ÖBOXµÄ¸ß¶ÈΪһ¶¨</div>
ÏÖ
ÔÚµÄЧ¹û£¬IEÖÐû±£³Ö×îС¸ß¶ÈΪ150px¡£
½â¾öµÄ·½·¨
ΪIEÉ趨һ¸ö¸ß¶È
* html div.box1,* html div.box2{height: 150px;}
wellstyled.com µÄ
½â¾ö·½·¨ÊDzÉÓà CSS µÄÊôÐÔÑ¡Ôñ·û£¨Attribute Selectors£©
div.box1,div.box2{ ......height: 150px;}
/* IE¿¿Õâ±£
³Ö×îС¸ß¶È£¬³¬³ö¾Í×Ô¶¯ÏòÏÂÑÓÉì */
div[class].box1,div[class].box2{height: auto;}
/* ¾ß
ÓÐÀàÑ¡Ôñ·û(class)ÊôÐÔµÄDIV¶ÔÏó */
IE×ÔÈ»ÓÖÊDz»Ö§³ÖµÄÀ²£¬Opera ºÍ Mozilla Ö§
³Ö£¬¶ÁÈ¡Õâ¸ö¸ß¶È¡£¿ÉÓ¦Óó¡ºÏ£ºËÑË÷¡¢ÎÄÕµÈÒ³Ãæ£¨Ã»²ÉÓÃ100%¸ß¶È£¬µ±Ëѵ½µÄÄÚÈݽÏÉÙʱ£¬²»ÖÁÓÚÒ³ÃæÌ«¶Ì¡£
Ïà¹ØÎĵµ£º
ÔÚǰ¶Ë¿ª·¢ÖУ¬ÎÒÃǾ³£Óöµ½ÕâÑùµÄÇé¿ö£º·þÎñÆ÷´«µ½Ç°¶ËµÄͼƬÐèÒªËõСÒÔÏÔʾ£¨ÈçÏ£©£¬ÔÚ½«ÆäËõ·ÅÖ®ºó£¬IEÖÐͼƬЧ¹û²»ÈÝÀÖ¹Û¡£
<img class="thumb" src=http://www.webyi.com/wschool/wdesign/CSS/20090905/"pic.jpg" alt="This image is really 500x500 big" width="50" height="50" />
IE7Ö§³Ö×Ô¶¨ÒåË«Èý´Î&ldq ......
CSS±³¾°ÊôÐÔ
±³¾°ÑÕÉ«ÊôÐÔ(background-color)
Õâ¸öÊôÐÔΪHTMLÔªËØÉ趨±³¾°ÑÕÉ«£¬Ï൱ÓÚHTMLÖÐbgcolorÊôÐÔ¡£
body {background ......
ÎÒÃÇ´Ó52CSS.comÖÐѧϰDivCSSÍøÒ³²¼¾ÖµÄ֪ʶ£¬¿ÉÊÇW3C validationÓÐʱÄÑÒÔ²Ù×÷£¬µ«ÓÃËüÄã¿ÉÒԲ鿴ÓɰæÃæÉè¼ÆÒýÆðµÄ²î´í¡£ÑéÖ¤³ÌÐòÅ׳ö´óÁ¿²î´íºÍ¾¯¸æ£¬ËµÃ÷ÄãµÄXHTMLÉÐδÍêÉÆ£¬¿ÉÄÜÎÞ·¨ÔÚ²»Í¬ä¯ÀÀÆ÷Éϱ£³ÖÒ»Ö¹¦ÄÜ¡£ÏÂÃæÊ®¸öϸ΢µÄʧЧÎÊÌâÄÑסÁË´óÅú³ÌÐòÔ±£¬±¾Îľ͸æËßÄãÈçºÎ½â¾ö¡£ÔÚ±¾ÎÄ¿ªÊ¼Ç°½éÉÜһР......
Block element ¿é¼¶ÔªËØ
¹ËÃû˼Òå¾ÍÊÇÒÔ¿éÏÔʾµÄÔªËØ£¬¸ß¶È¿í¶È¶¼ÊÇ¿ÉÒÔÉèÖõġ£±ÈÈçÎÒÃdz£ÓõÄ<div>¡¢<p>¡¢<ul>ĬÈÏ״̬϶¼ÊÇÊôÓÚ¿é¼¶ÔªËØ¡£¿é¼¶ÔªËرȽϰԵÀ£¬Ä¬ÈÏ״̬ÏÂÿ´Î¶¼Õ¼¾ÝÒ»Õû¸öÐУ¬ºóÃæµÄÄÚÈÝÒ²±ØÐëÔÙÐÂÆðÒ»ÐÐÏÔʾ¡£µ±È»·Ç¿é¼¶ÔªËØÒ²¿ÉÒÔͨ¹ýcssµÄdisplay:block;½«Æä¸ü¸Ä³É¿é¼¶ÔªËØ¡£´ËÍâ» ......
Css¶¨ÖÆDrupalÖ÷Ìâ·ç¸ñ
¡¡¡¡“Ö÷Ìâ”ÊÇDrupalÕ¾µãµÄ»ù±¾ÍâòºÍ¸Ð¾õ¡£ÓÐʱһ¸öÌØ¶¨µÄÕ¾µã»á°²×°²»Ö¹Ò»¸öµÄÖ÷Ìâ¡£Èç¹ûÕ¾µã¹ÜÀíÔ±ÌṩÁ˶à¸öÖ÷Ì⣬Äã¿ÉÒÔΪÄãµÄÕʺÅÑ¡ÔñÄãϲ»¶µÄĬÈÏÖ÷Ìâ¡£
¡¡¡¡DrupalµÄ¹Ù·½Õ¾µãÌṩÁËÐí¶àÖ÷Ìâ·ç¸ñ£¬¾ßÌå¼û£º
¡¡¡¡http://drupal.org/project/Themes
¡¡¡¡ÆäÖУ¬SpreadfirefoxÊÇÎ ......