Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
浅谈表单元素
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
w3cplus
December 12, 2012
Technology
630
3
Share
浅谈表单元素
详细介绍了表单元素的制作
w3cplus
December 12, 2012
More Decks by w3cplus
See All by w3cplus
手淘互动动效探索
w3cplus
0
250
CSS Future
w3cplus
2
640
Web Animation
w3cplus
5
500
CSS3带来的变化
w3cplus
0
1.5k
Web重构之道
w3cplus
1
2.9k
Sass带来的变革
w3cplus
2
630
Responsive小试牛刀
w3cplus
3
570
CSS预处器——Sass、LESS和Stylus实践
w3cplus
0
400
http协议与缓存简述
w3cplus
5
540
Other Decks in Technology
See All in Technology
LLM とプロンプトエンジニアリング/チューターを定義する / LLMs and Prompt Engineering, and Defining Tutors
ks91
PRO
0
350
終盤で崩壊させないAI駆動開発
j5ik2o
0
650
Bill One 開発エンジニア 紹介資料
sansan33
PRO
5
18k
すごいぞManaged Kubernetes
harukasakihara
1
400
みんなで作るAWS Tips 100連発 (FinOps編)
schwrzktz
1
120
AIペネトレーションテスト・ セキュリティ検証「AgenticSec」ご紹介資料
laysakura
0
1.7k
Azure PortalなどにみるWebアクセシビリティ
tomokusaba
0
120
インフラを Excel 管理していた組織が 3 ヶ月で IaC 化されるまで
geekplus_tech
3
190
20260410 - CNTUG meetup #72 - DiskImage Builder 介紹:以 Kubespray CI 打造 RockyLinux 10 Cloud Image 為例
tico88612
0
120
さくらのクラウドでつくるCloudNative Daysのオブザーバビリティ基盤
b1gb4by
0
160
3つのボトルネックを解消し、リリースエンジニアリングを再定義した話
nealle
0
410
🀄️ on swiftc
giginet
PRO
0
340
Featured
See All Featured
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
150
Tell your own story through comics
letsgokoyo
1
890
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
61
43k
Balancing Empowerment & Direction
lara
5
1k
What does AI have to do with Human Rights?
axbom
PRO
1
2.1k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
510
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
YesSQL, Process and Tooling at Scale
rocio
174
15k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.3k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
710
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
160
We Have a Design System, Now What?
morganepeng
55
8.1k
Transcript
浅谈表单元素 作者:为之,前端工程师 官网:http://www.w3cplus.com 微博:http://weibo.com/w3cplus
提纲 部分表单元素的一些简单分析 平时表单的需求分析 form.css实战 表单元素的美化
1、部分表单元素的一些简单分析 �radio & checkbox �submit 等btn 参考资料: input 按钮在IE下兼容问题 表单button的行高问题
如何移除button在IE67下的黑边 修复iPhone上submit按钮bug form radio & checkbox解决方案 submit提交按钮解决方案
1、部分表单元素的一些简单分析 参考资料: select的最佳预设 IE下 z-index 的各种坑 最佳预设 ie6层级问题 �select
1、部分表单元素的一些简单分析 参考资料: Styling the HTML5 placeholder HTML5, Placeholder, line-height in
Webkit Making HTML5 input placeholder text behave in Safari normalize.css WebKit HTML5 Search Inputs safari bug 定义样式 �placeholder �type="search"
2、表单元素需求分析 �水平label �垂直label �水平radio & checkbox �垂直radio & checkbox
2、表单元素需求分析 �提示文字 �提示文字用placeholder来搞定 �报错信息 或 在右侧显示span 单行显示,在表单顶部或底部p
2、表单元素需求分析 �一个label多个表单元素 �label加文字 �多个label多个元素
3、form.css 好了,是时候跟那些变态的需求说bye bye了 form.css 简单来说,form.css能帮助你快速完成上述的各种变态需求 当然看起来结构有点臃肿,但是到目前为止,所有的结构标 签都是必须的,真的没有多余可说,所以它能够面临上述所 有的各种变化需求。 参考资料: form解决方案
3、form.css css之所以能有用,当然得取决于一定结构的html 参考资料: form表单结构 .form-horizontal, .form-vertical .form-item, .form-radio-checkbox-wrap, .item-no-label, .form-action,
.inline-form-item .form-field .form-text, .form-radio, .form-checkbox, .code-pic, .inputbtn select,textarea .field-list-block, .inline-ele .form-error, .form-alert, .form-notice, .form-success, .form-info .fele
3、form.css �文本框 �textarea NO file �radio & checkbox
3、form.css �验证码 �条款,自动登录 NO file �select �submit
参考资料: 美化表单——自定义单选按钮和复选按钮 美化表单——自定义checkbox和radio样式 自定义表单——美化你的文件载入框 使用CSS3的appearance属性改变元素的外观 4、表单元素美化
4、谢谢 建议或疑问 email:['xuyc_brother','foxmail.com'].join('@') qq:'623089826'.replace(/8/g,'5') http://www.w3cplus.com