發表文章

目前顯示的是有「CSS」標籤的文章

input css

.nput { width: 100%; height: 45px; padding: 0 8px; border: 1px solid #bebebe; outline: none; font-size: 14px; -webkit-border: 1px solid #ffd0ad; -moz-border: 1px solid #ffd0ad; -webkit-appearance: none; box-sizing:border-box; -moz-box-sizing:border-box; /* Firefox */ -webkit-box-sizing:border-box; /* Safari */ -moz-border-radius: 5px;     -webkit-border-radius: 5px;     border-radius: 5px; }

CSS手機橫向字體不放大

< style   type = "text/css" > body { -webkit-text-size-adjust:100%;/*手機橫向不放大*/ overflow-x:hidden; } < / style >

textarea禁止換行、不顯示捲軸

< style   type = "text/css" > textarea {         white-space: nowrap; /* 禁止換行 */         overflow: hidden; /* 不顯示捲軸 */         resize:none; /* 禁止瀏覽器拖放區塊大小 */ } < / style > <!-- 使用onkeydown事件讓Enter鍵失效 --> < textarea   onkeydown = "if(event.keyCode == 13) return false;" > I'm Textarea!! < / textarea >

常用CSS

初始化所有margin/padding影響的寬,會影響fancybox的寬 { box-sizing:border-box; -moz-box-sizing:border-box; /* Firefox */ -webkit-box-sizing:border-box; /* Safari */ } map 的 area 点击在IE下出现虚框 white-space: nowrap; 上標字 vertical-align: super; 下標字 vertical-align: sub; 強制不換行 white-space: nowrap; 最前及最後 :first-child :last-child CSS :after 伪元素 :after {content:url(/i/w3school_logo_white.gif)} 隱藏li連結文字 text-indent:-9999px; 文字平均齊尾 text-align:justify; 輸入框沒有外光暈 outline: none; 命令物件出現手指游標 cursor:pointer; 消除影像地圖按下後產生的連結虛線框 <img src="http://img.minwt.com/img/Content/noimg.jpg" hidefocus="true"/> iframe透明背景 iframe.htm <iframe src="SourcePage.htm" allowtransparency="true"></iframe> SourcePage.htm 加在<body …..之後 style="background-color:transparent" 清除div結尾之前物件浮動 div/class name:after{visibility: hidden; display: block; font-size: 0; content: " "; clear: both; height: 0; } list-style-type 属性 cjk-i...