css²Ëµ¥µ¼º½
ÕâÊÇÎÒÔÚÒ»¸öÍøÕ¾ÉÏ¿´µ½µÄ,CSS¿ØÖÆÒ»¸ö²Ëµ¥,ºÜ¾µäʵÓÃ
CssÎļþÈçÏÂ:css.css
@charset "UTF-8";
/* navigation.css
$Revision: 1.0 $
(c) 2008 Fortinet, Inc. All rights reserved.
*/
/* Navigation Styles ------------------------------------------- */
#wrapper
{
width:1000px;margin:0 auto;
}
#nav_bar {
clear: both;
background: url(./menu_bkrd.jpg) repeat-x;
height: 26px;
width: 100%;
}
#navigation {
padding: 0 0 0 10px;
}
#nav, #nav ul {
float: left;
list-style: none;
line-height: 1;
padding: 0 0 0 0; /* 0 0 0 0.5em; */
margin: 0; /* 0 0 1em 0; */
/* border: solid 1px #33FF00; /* (Green) remove this item after testing */
width:auto;
}
#nav a {
font: 11px/12px Tahoma, Arial, Helvetica, Verdana, sans-serif;
color: #6a737b;
display: block;
width: 150px; /* 6em; 3em; 10em -- 150px*/
text-decoration: none;
padding: 7px 10px 4px 6px; /* 0.5em 3.5em 0.2em .5em; 0.4em 0 0.2em 0; // 0.4em 2em 0.2em 2em; // 0.5em 2em; */
margin: 0px; /* 0.5em 2em; uncommented - fixes extra space on right for IE 0 0 0 1px */
/* border: solid 1px #FF0000; /* (Red) remove this item after testing */
}
#nav a.top_nav {
font: 12px Arial, Helvetica, sans-serif;
color: #6a737b;
text-align: center;
width: 90px;
margin: 0;
padding: 6px 0 4px 0;
text-decoration: none;
font-weight: bold;
white-space: nowrap; /* */
}
#nav a.nav_parent {
background: url(./rightarrow.gif) center right no-repeat;
/* white-space: nowrap; /* */
/* border: solid 1px #FFFF00; /* (yellow) remove this item after testing */
}
#nav li {
/*float: left;*/
padding: 0;
/* width: 150px; /* 7.5em; 10em; 12em 178px; this has no affect whatsoever */
/* border: solid 1px #FFFF00; /* (yellow) remove this item after testing */
}
#nav li.top_nav
Ïà¹ØÎĵµ£º
±¾ÎÄÁоÙÁ˼æÈÝ IE ºÍ FF µØ»»ÐÐ CSS ÍÆ¼öÑùʽ,Ïêϸ½éÉÜÁËword-wrapͬword-breakµØÇø±ð.¼æÈÝ IE ºÍ FF µØ»»ÐÐ CSS ÍÆ¼öÑùʽ£º
×îºÃµØ·½Ê½ÊÇ
word-wrap:break-word; overflow:hidden;
¶ø²»ÊÇ
word-wrap:break-word; word-break:break-all;
Ò²²»ÊÇ
word-wrap:break-word; overflow:auto;
ÕâÖÖ×îºÃµØ·½Ê½,ÔÚ IE ÏÂûÓÐÈ ......
ËäÈ»CSSÑùʽµÄѧϰÐèÒªÎÒÃǶ¯ÊÖ¶àʵ¼ù£¬ÐèÒª¶à×ö°¸Àý£¬Ë¼ÖÂ˼¿¼£¬µ«ÓÐʱºò×¢Òâ×ÊÁϵÄÊÕ¼¯ÓëÕûÀíÒ²ÊǷdz£ÖØÒªµÄ£¬ÔÚʵ¼Ê¿ª·¢ÖÐÍùÍù»áÆðµ½Ê°빦±¶µÄЧ¹û¡£ÔÚwww.phpq.netµÄÎĵµÖУ¬Ò²ÌṩÁ˷ḻµÄÄÚÈÝ¡£ÏÂÃæÒ»Ð©¹ØÓÚ°´Å¥¡¢Îı¾¿ò¡¢±íµ¥µÄ³£ÓÃCSSÑùʽ¡£´ó¼Ò¿ÉÒԲο¼¡£
Ò»¡¢°´Å¥Ñùʽ
.buttoncss {
font-family: "tahoma", ......
¼¸¸öcssÔªËØµÄ¼òµ¥½âÊÍ div ul dl dt oldiv£¬Õâ¸öºÜ³£¼û£¬¿é¼¶ÔªËØ£¬div¾¡Á¿ÉÙÓ㬺ÍtableÒ»Ñù£¬Ç¶Ì×Ô½ÉÙÔ½ºÃ
ol ÓÐÐòÁÐ±í¡£
<ol>
<li>……</li>
<li>……</li>
<li>……</li>
</ol>
±íÏÖΪ£º
1……
2…& ......
ͼƬ×Ô¶¯ÊÊÓ¦´óСµÄÎÊÌâÔÚÆ½Ê±ÖÆ×÷µÄʱºòÊDZȽϳ£¼ûµÄÎÊÌ⣬ÏÂÃæÌṩһ¸ö±È½Ï¼òµ¥µÄ½â¾ö·½·¨£º
div img {
max-width:600px;
//IE7¡¢FFµÈÆäËû·ÇIEä¯ÀÀÆ÷ÏÂ×î´ó¿í¶ÈΪ600px;
width:600px;
//ËùÓÐä¯ÀÀÆ÷ÖÐͼƬµÄ´óСΪ600px;
width:expression(document.body.clientWidth>600?"600px":"auto");
//µ±Í¼Æ¬´óС´óÓÚ6 ......
<style type="text/css">
<!--
input{ background:expression((this.readOnly &&this.readOnly==true)?"#CCCCCC":"")}
-->
</style>
<body>
<input type="text" name="" />
<input type="text" name="" readonly="readonly" />
expression:´¦Àí·½Ê½£º
  ......