-
Notifications
You must be signed in to change notification settings - Fork 2
/
add-ngo.php
176 lines (143 loc) · 7.8 KB
/
add-ngo.php
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
171
172
173
174
175
176
<!DOCTYPE html>
<html>
<head>
<!--Import Google Icon Font-->
<link href="http://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!--Import materialize.css-->
<link type="text/css" rel="stylesheet" href="css/materialize.min.css" media="screen,projection"/>
<link rel="stylesheet" type="text/css" href="css/main.css">
<meta charset="utf-8">
<meta name="language" content="en-us"/>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
<meta name="description" content="Team Relief Chennai | We are a small group of people who took up an initiative to help and rescue people stuck up in floods in Chennai.
" />
<meta name="keywords" content="Chennai, Rains, Floods, pray for chennai, chennai rains, rescue, help, ngo, chennai support, chennai sos, chennai emergency" />
<meta name="distribution" content="Global" />
<meta name="robots" content="index, follow" />
<meta name="revisit-after" content="1 days"/>
<meta name="copyright" content="Relief Chennai"/>
<!--Let browser know website is optimized for mobile-->
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
</head>
<?php
include 'funcs.php';
include 'navbar.php';
///backend code to Help/Volunteer
if (isset($_POST['name'])) {
# code...
$name = $_POST['name'];
$contact = $_POST['contact'];
$address = $_POST['address'];
$area_covered= $_POST['area'];
$type_of_help = $_POST['type_of_help'];
addNGO($_POST['name'],$_POST['address'], $_POST['contact'], $_POST['type_of_help'], $_POST['area']);
echo ' <div class="row">
<div class="grid-example col s12 l12 m12"><span class="flow-text">Thankyou for your support. Your response is recorded and would be shown in our database. <a href = "index.php" >Go Back</a></span></div></div>';
}
else {
?>
<body>
<?php
include 'analyticstracking.php';
?><title>ReliefChennai-An initiative by VIT'ains</title>
<div class="row">
<br>
<div class="col m4 l3 hide-on-med-and-down navleft"> <!-- Note that "m4 l3" was added -->
<!-- Grey navigation panel
This content will be:
3-columns-wide on large screens,
4-columns-wide on medium screens,
12-columns-wide on small screens -->
<div class="collection">
<a href="find-ngo.php" class="collection-item">Locate NGO/Help<span class="badge"><?php echo NumberOfPeopleWhoAreHelping(); ?></span></a>
<a href="help-needed.php" class="collection-item">Help Needed<span class="badge"><?php echo NumberOfPeopleWhoWantHelp(); ?></span></a>
<a href="need-help.php"class="collection-item" >Request Help</a>
<a href="livestatus.php"class="collection-item" >Live Status</a>
<a href="safe.php" class="collection-item">Find Safe Place</a>
<a href="add-ngo.php" class="collection-item">Help/Volunteer</a>
<a href="donate.php"class="collection-item" >Donate</a>
<a href="news.php"class="collection-item" >Follow the news</a>
<a href="helpline.php" class="collection-item">Helpline</a>
<a href="raillines.php" class="collection-item">Petrol and RailLine Services</a>
<a href="sos.php" class="collection-item">Chennai Flood Reliefs</a> <!-- Dropdown Trigger -->
<a class="collection-item" data-beloworigin="true" href="#!" ><span>Emergency<i class="material-icons right">arrow_drop_down</i></span></a>
<ul>
<li><a href="#!">Fire & rescue : <p><a href="tel:101">101</a></p></a></li>
<li class="divider"></li>
<li><a href="#!">Electricity : <p><a href="tel:1912">1912</a></p></a></li>
<li class="divider"></li>
<li><a href="#!">District Emergency: <p>1077</p></a></li>
<li class="divider"></li>
<li><a href="#!">State Emergency:<p> 1070 </p></a></li>
</ul>
</div>
</div>
<div class="col s12 m12 l9"> <!-- Note that "m8 l9" was added -->
<!-- Teal page content
This content will be:
9-columns-wide on large screens,
8-columns-wide on medium screens,
12-columns-wide on small screens -->
<br><br>
<div class="row">
<div class="grid-example col s12 l12 m12"><span class="flow-text">If you want to help, please fill up the form</span></div>
</div>
<div class="row center-align">
<form class="col s12" id = "addNGO" method = "POST" action = "add-ngo.php">
<div class="row">
<div class="input-field col s12 l6 m12 ">
<input name = "name" placeholder="Your name or NGO name" id="first_name" type="text" class="validate" required>
<label for="first_name">Name</label>
</div>
<div class="row">
<div class="input-field col s12 l6 m12">
<input name = "contact" placeholder="Your Contact Number" id="first_name" type="text" class="validate" required>
<label for="first_name">Contact</label>
</div>
</div>
<div class="row">
<div class="input-field col s12 l6 m12">
<textarea name = "address" id="textarea1" class="materialize-textarea"></textarea>
<label for="textarea1">Address</label>
</div>
</div>
<div class="row">
<div class="input-field col s12 l6 m12">
<input name = "area" placeholder="Area you can reach" id="first_name" type="text" class="validate" required>
<label for="first_name">Area Reachable</label>
</div>
</div>
<div class = "row">
<div class = "input-field col s12 l6 m12">
<label>Type of help</label><br><br>
<select class="browser-default" name = "type_of_help">
<option value="" disabled selected>Choose an option</option>
<option value="Food">Food</option>
<option value="Evacuation">Evacuation</option>
<option value="Venue">Shelter</option>
<option value="Medical">Medical</option>
<option value="Other">Other</option>
</select>
</div>
</div>
</div>
<a class="waves-effect waves-light btn" id= "submitForm">Submit</a>
</form>
</div>
<!--Import jQuery before materialize.js-->
<script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<script type="text/javascript" src="js/materialize.min.js"></script>
<script type="text/javascript">
document.getElementById("submitForm").onclick = function() {
document.getElementById("addNGO").submit();
}
</script>
</body>
</html>
<?php
}
?>
</div>
</div>