-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
170 lines (165 loc) · 6.74 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title></title>
<!-- bootstrap -->
<link rel="stylesheet" type="text/css" href="./styles/bootstrap.min.css">
<!-- my own stylesheet -->
<link rel="stylesheet" type="text/css" href="./styles/main.css">
</head>
<body>
<nav class="navbar navbar-inverse" role="navigation">
<div class="container-fluid">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-ex1-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">ALC Phone-Book</a>
</div>
<!-- /.navbar-collapse -->
</div>
</nav>
<div class="container-fluid">
<h1 class="text-center">ALC Address book</h1>
</div>
<div class="container">
<button type="button" class="btn btn-info btn-lg" data-toggle="modal" data-target="#myModal">Add New Contact</button>
</div>
<div class="container">
<div class="row">
<div class="col-md-6 contacts">
<h2>Contacts</h2>
<ul id="contact-list">
</ul>
</div>
<div class="col-md-6 contact-details">
<h2>Contact Details</h2>
<h3 id="contactName">Name:</h3>
<h3 id="contactMobile">Mobile:</h3>
<h3 id="contactPhone">Phone:</h3>
<h3 id="contactEmail">Email:</h3>
<h3 id="contactAddress">Address:</h3>
<div class="options">
<button type="button" class="btn btn-success btn-lg" data-toggle="modal" data-target="#editModal" id="edit">Edit</button>
<button type="button" class="btn btn-danger btn-lg" data-toggle="modal" id="delete">Delete</button>
</div>
</div>
</div>
</div>
<!-- Modal -->
<div id="myModal" class="modal fade" role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title" id="instruction">Enter Contact Details</h4>
</div>
<div class="modal-body">
<form class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2" for="name">Name:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="name" required="" placeholder="Contact's name">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="phone">Phone:</label>
<div class="col-sm-8">
<input type="phone" class="form-control" id="phone" placeholder="Contact's Phone">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="mobile">Mobile:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="mobile" placeholder="Contact's Mobile">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="address">Address:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="address" placeholder="Contact's address">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="email">Email:
</label>
<div class="col-sm-8">
<input type="email" class="form-control" id="email" placeholder="Contact's Email">
</div>
</div>
</form>
</div>
<div class="modal-footer">
<button type="save" class="btn btn-success btn-lg" id="submit">Save</button>
<button type="button" class="btn btn-danger btn-lg" data-dismiss="modal">Cancel</button>
</div>
</div>
</div>
</div>
<!-- edit button modal -->
<!-- Modal -->
<div id="editModal" class="modal fade" role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title" id="instruction">Edit Contact Details</h4>
</div>
<div class="modal-body">
<form class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2" for="name">Name:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="nameEdit" required="" placeholder="Contact's name">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="phone">Phone:</label>
<div class="col-sm-8">
<input type="phone" class="form-control" id="phoneEdit" placeholder="Contact's Phone">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="mobile">Mobile:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="mobileEdit" placeholder="Contact's Mobile">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="address">Address:</label>
<div class="col-sm-8">
<input type="text" class="form-control" id="addressEdit" placeholder="Contact's address">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="email">Email:
</label>
<div class="col-sm-8">
<input type="email" class="form-control" id="emailEdit" placeholder="Contact's Email">
</div>
</div>
</form>
</div>
<div class="modal-footer">
<button type="save" class="btn btn-success btn-lg" id="submitEdit">Save</button>
<button type="button" class="btn btn-danger btn-lg" data-dismiss="modal">Cancel</button>
</div>
</div>
</div>
</div>
<!-- jquery -->
<script type="text/javascript" src="./scripts/jquery-3.2.1.min.js"></script>
<!-- bootstrap js -->
<script type="text/javascript" src="./scripts/bootstrap.min.js"></script>
<script type="text/javascript" src="./scripts/main.js"></script>
</body>
</html>