<form method="" action="" class="form-horizontal">
<frameset>
<div class="control-group">
<label class="control-label" for="tb_userName">UserName:</label>
<div class="controls">
<input id="tb_userName" placeholder="Please input your user name." type="text" />
<p class="help-block">Please enter a user name you want to register.</p>
</div>
</div>
<div class="control-group">
<label class="control-label" for="tb_password">Password:</label>
<div class="controls">
<input id="tb_password" placeholder="Please input your password." type="text" />
<p class="help-block">Please enter a password you want to register.</p>
</div>
</div>
</frameset>
<div class="form-actions">
<button type="submit" class="btn btn-primary">submit</button>
</div>
</form>

先看Bootstrap下表单的效果

添加一些 分组元素后 代码如下:

  <form method="" action="" class="form-horizontal">
<fieldset>
<div class="control-group">
<label class="control-label" for="tb_userName">UserName:</label>
<div class="controls">
<input id="tb_userName" placeholder="Please input your user name." type="text" />
<p class="help-block">Please enter a user name you want to register.</p>
</div>
</div>
<div class="control-group">
<label class="control-label" for="tb_password">Password:</label>
<div class="controls">
<input id="tb_password" placeholder="Please input your password." type="text" />
<p class="help-block">Please enter a password you want to register.</p>
</div>
</div>
</fieldset>
<div class="form-actions">
<button type="submit" class="btn btn-primary">submit</button>
</div>
</form>

效果:

这里要注意的是 fieldset 元素可将表单内的相关元素分组。

BootStrap2学习日记12---注册表单的更多相关文章

  1. Ruby Rails学习中:注册表单,注册失败,注册成功

    接上篇 一. 注册表单 用户资料页面已经可以访问了, 但内容还不完整.下面我们要为网站创建一个注册表单. 1.使用 form_for 注册页面的核心是一个表单, 用于提交注册相关的信息(名字.电子邮件 ...

  2. html学习之简单注册表单

    <html> <head> <title>新用户注册</title> <meta charset="utf-8"> &l ...

  3. 20151222jquery学习笔记--验证注册表单

    $(function () { $('#search_button').button({ icons : { primary : 'ui-icon-search', }, }); $('#reg'). ...

  4. UX设计秘诀之注册表单设计,细节决定成败

    以下内容由摹客团队翻译整理,仅供学习交流,摹客iDoc是支持智能标注和切图的产品协作设计神器. 说实话,现实生活中,又有多少人会真正喜欢填写表格?显然,并不多.因为填写表单这样的网页或App服务,并非 ...

  5. CSS3制作分步注册表单

    这个DEMO是使用CSS3制作的一个分步注册表单,每个input对应的是每一步,在表单得到焦点时,对应的step也会进行对应的改变.不过这个效果是使用js代码来实现,但整个表单的外观是由CSS3来完成 ...

  6. Html注册表单示例

    注册表单示例,出自<网页开发手记:Html,CSS,JavaScript实战详解>.   <html>   <head>   <title>注册表单&l ...

  7. 免费 PSD 下载: 20个精美的登录和注册表单

    注册表单有许多不同的形状和尺寸,有的只是单个的输入框,有的则需要多个步骤.登录表单的设计将定义网站的性质,因此它应进行针对性的设计.下面的列表提供了20个醒目的登录和注册表单设计为您提供灵感. 您可能 ...

  8. Ext JS4 学习笔记之发送表单(Form)时也将表单下的表格(Grid)数据一同发送的方法

    Ext JS4 学习笔记之发送表单(Form)时也将表单下的表格(Grid)数据一同发送的方法 昨天在开发的时候遇到个小问题,就是如何将Grid的内容与Form一起发送到服务器端.默认情况下,表单(F ...

  9. 如何利用WordPress创建自定义注册表单插件

    来源:http://www.ido321.com/1031.html 原文:Creating a Custom WordPress Registration Form Plugin 译文:创建一个定制 ...

随机推荐

  1. HBase Shell手动移动Region

    在生产环境中很有可能有那么几个Region比较大,但是都运行在同一个Regionserver中. 这个时候就需要手动将region移动到负载低的Regionserver中. 步骤: 1.找到要移动的r ...

  2. Java8新特性 1——利用流和Lambda表达式操作集合

    Java8中可以用简洁的代码来操作集合,比如List,Map,他们的实现ArrayList.以此来实现Java8的充分利用CPU的目标. 流和Lambda表达式都是Java8中的新特性.流可以实现对集 ...

  3. homework-08-作业2

    1. 了解Lambda的用法 计算“Hello World!”中 a.字母‘e’的个数 b. 字母‘l’的个数 代码: void calcEL() { char s[100] = "Hell ...

  4. 在Linux下部署activemq

    今天的任务就是在一台新的服务器上继续部署activemq.其实都蛮简单的.首先先下载包:115U盘下载 2 上传到linux下的某个文件夹下.解压缩 tar -zxvf apache-activemq ...

  5. WinForm开发浏览器,WebBrowser获取页面内容,如何解决中文乱码

    WebBrowser的编码可以从文档对象中获得,将代码改为如下即可. System.IO.StreamReader getReader = new System.IO.StreamReader(thi ...

  6. AngularJS~大话开篇

    AngularJS是一款优秀的前端JS框架,已经被用于Google的多款产品当中.AngularJS有着诸多特性,最为核心的是:MVVM.模块化.自动化双向数据绑定.语义化标签.依赖注入.等等. 前端 ...

  7. PostgreSQL的 initdb 源代码分析之四

    继续分析: if (pwprompt && pwfilename) { fprintf(stderr, _("%s: password prompt and password ...

  8. NEUOJ 1117: Ready to declare(单调队列)

    1117: Ready to declare 时间限制: 1 Sec  内存限制: 128 MB 提交: 358  解决: 41 [提交][状态][pid=1117" style=" ...

  9. 【M26】限制某个class所能产生的对象数量

    1.每当产生一个对象,必定调用构造方法.因此,禁止产生对象的做法就是,将所有的构造方法声明为private. 2.只有在类的内部才可以访问private成员,有两层含义:在类的内部可以访问this的p ...

  10. Codeforces Gym 100571A A. Cursed Query 离线

    A. Cursed QueryTime Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/gym/100571/problem ...