Skip to content

Commit a9b9dfe

Browse files
committed
Sexier forms.
1 parent 4c34b2f commit a9b9dfe

File tree

2 files changed

+50
-24
lines changed

2 files changed

+50
-24
lines changed
Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,20 @@
1-
<form name="loginForm" ng-controller="UserController"
2-
ng-submit="login()" novalidate>
3-
<label for="username">Username:</label>
4-
<input type="text" id="username"
5-
ng-model="username">
6-
<label for="password">Password:</label>
7-
<input type="password" id="password"
8-
ng-model="password">
9-
<button type="submit">Login</button>
1+
<form name="loginForm" ng-controller="UserController" ng-submit="login()"
2+
class="form-horizontal" novalidate>
3+
<div class="form-group">
4+
<div class="col-md-3">
5+
<input type="text" id="username" ng-model="username"
6+
class="form-control" placeholder="Username">
7+
</div>
8+
</div>
9+
<div class="form-group">
10+
<div class="col-md-3">
11+
<input type="password" id="password" ng-model="password"
12+
class="form-control" placeholder="Password">
13+
</div>
14+
</div>
15+
<div class="form-group">
16+
<div class="col-md-4">
17+
<button type="submit" class="btn btn-primary">Login</button>
18+
</div>
19+
</div>
1020
</form>
Lines changed: 31 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,32 @@
1-
<form name="loginForm" ng-controller="UserController"
2-
ng-submit="create()" novalidate>
3-
<label for="username">Username:</label>
4-
<input type="text" id="username"
5-
ng-model="username">
6-
<label for="username">Email:</label>
7-
<input type="text" id="email"
8-
ng-model="email">
9-
<label for="password">Password:</label>
10-
<input type="password" id="password"
11-
ng-model="password">
12-
<label for="passwordConfirmation">Password Confirmation:</label>
13-
<input type="password" id="passwordConfirmation"
14-
ng-model="passwordConfirmation">
15-
<button type="submit">Login</button>
1+
<form name="loginForm" ng-controller="UserController" ng-submit="create()"
2+
class="form-horizontal" novalidate>
3+
<div class="form-group">
4+
<div class="col-md-3">
5+
<input type="text" id="username" ng-model="username"
6+
class="form-control" placeholder="Username">
7+
</div>
8+
</div>
9+
<div class="form-group">
10+
<div class="col-md-3">
11+
<input type="text" id="email" ng-model="email"
12+
class="form-control" placeholder="Email">
13+
</div>
14+
</div>
15+
<div class="form-group">
16+
<div class="col-md-3">
17+
<input type="password" id="password" ng-model="password"
18+
class="form-control" placeholder="Password">
19+
</div>
20+
</div>
21+
<div class="form-group">
22+
<div class="col-md-3">
23+
<input type="password" id="passwordConfirmation" ng-model="passwordConfirmation"
24+
class="form-control" placeholder="Password again">
25+
</div>
26+
</div>
27+
<div class="form-group">
28+
<div class="col-md-4">
29+
<button type="submit" class="btn btn-primary">Sign Up</button>
30+
</div>
31+
</div>
1632
</form>

0 commit comments

Comments
 (0)