-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathsubmit.html
More file actions
168 lines (138 loc) · 7.78 KB
/
submit.html
File metadata and controls
168 lines (138 loc) · 7.78 KB
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
<!doctype html>
<!-- https://getbootstrap.com/docs/4.4/components/alerts/ -->
<html>
<head>
<title>UpHelping</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<meta property="og:site_name" content="UpHelping" />
<meta property="og:title" content="Homeless Access Services" />
<meta property="og:description" content="Connecting the less fortunate with the resources they need to turn their life around" />
<meta property="og:image" content="me.png" />
<meta property="og:type" content="website" />
<link href="style.css" rel="stylesheet" type="text/css" />
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.7.2/animate.min.css" integrity="sha256-PHcOkPmOshsMBC+vtJdVr5Mwb7r0LkSVJPlPrp/IMpU=" crossorigin="anonymous" />
<link rel="apple-touch-icon" sizes="180x180" href="/icons/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/icons/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/icons/favicon-16x16.png">
<link rel="manifest" href="/icons/site.webmanifest">
<link rel="mask-icon" href="/icons/safari-pinned-tab.svg" color="#5bbad5">
<link rel="shortcut icon" href="/icons/favicon.ico">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-config" content="/icons/browserconfig.xml">
<meta name="theme-color" content="#ffffff">
</head>
<body class="markup">
<nav class="navbar navbar-expand-lg navbar-light bg-light fixed-top">
<a class="navbar-brand" href="index.html"><img src="ourlogo.png" height="60px" style="padding-right: 15px"></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNavDropdown">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link" href="index.html">Home</span></a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdownMenuLink" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
Resources
</a>
<div class="dropdown-menu" aria-labelledby="navbarDropdownMenuLink">
<a class="dropdown-item" href="shelters.html">Shelters</a>
<a class="dropdown-item" href="adhc.html">Addiction Centers</a>
<a class="dropdown-item" href="Fstability.html">Education</a>
<!-- <a class="dropdown-item" href="#">Resources for Women</a> -->
<a class="dropdown-item" href="crisis.html">Crisis</a>
<a class="dropdown-item" href="board.html">Community Board</a>
<a class="dropdown-item" href="submit.html">Submit a Resource</a>
</div>
</li>
</ul>
</div>
</nav>
<div class="container wow fadeIn delayed">
</br></br></br><br><br></br><br><br>
<div class="row">
<div class="col-md-3"></div>
<div class="col-md-6">
<h1 class="center">Submit a Resource</h1>
<p class="center">Use this space to post a resource that you believe will be helpful to the community. To create a post, simply add a short title for it and a brief description of it. Please do not make the description too long, and do note that the input will not recognize any line breaks that you enter.</p>
<div class="form-group">
<label for="exampleFormControlInput1">Title</label>
<input type="text" class="form-control" id="title" placeholder="Enter Title Here">
</div>
<div class="form-group">
<label for="exampleFormControlTextarea1">Description</label>
<textarea class="form-control" id="desc" rows="4" placeholder="Enter Description Here"></textarea>
</div>
<p class="center"><button class="btn btn-outline-secondary animated infinite slow pulse" onclick="submit()">Submit</button></p>
</div>
</div>
</div>
<br><br><br><br><br><br><br><br><br><br>
<p class="center small wow fadeIn ">© UpHelping 2020</p>
<!--Scripts: DO NOT TOUCH!-->
<script src="script.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.min.js" integrity="sha384-wfSDF2E50Y2D1uUdj0O3uMBJnjuUD4Ih7YwaYd1iqfktj0Uod8GCExl3Og8ifwB6" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.bundle.min.js" integrity="sha384-6khuMg9gaYr5AxOqhkVIODVIvm9ynTT5J4V1cfthmT+emCG6yVmEZsRHdxlotUnm" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.min.js" integrity="sha256-z6FznuNG1jo9PP3/jBjL6P3tvLMtSwiVAowZPOgo56U=" crossorigin="anonymous"></script>
<script>
var wow = new WOW(
{
boxClass: 'wow', // animated element css class (default is wow)
animateClass: 'animated', // animation css class (default is animated)
offset: 0, // distance to the element when triggering the animation (default is 0)
mobile: true, // trigger animations on mobile devices (default is true)
live: true, // act on asynchronously loaded content (default is true)
callback: function(box) {
// the callback is fired every time an animation is started
// the argument that is passed in is the DOM node being animated
},
scrollContainer: null // optional scroll container selector, otherwise use window
}
);
wow.init();
</script>
<!-- The core Firebase JS SDK is always required and must be listed first -->
<script src="https://www.gstatic.com/firebasejs/7.7.0/firebase-app.js"></script>
<!-- TODO: Add SDKs for Firebase products that you want to use
https://firebase.google.com/docs/web/setup#available-libraries -->
<script src="https://www.gstatic.com/firebasejs/7.7.0/firebase-analytics.js"></script>
<script src="https://www.gstatic.com/firebasejs/7.7.0/firebase-firestore.js"></script>
<script>
// Your web app's Firebase configuration
var firebaseConfig = {
apiKey: "AIzaSyDg77Xo_rffczrVHH2J5MJ1e3Wmy900C3Y",
authDomain: "uphelping-6aa09.firebaseapp.com",
databaseURL: "https://uphelping-6aa09.firebaseio.com",
projectId: "uphelping-6aa09",
storageBucket: "uphelping-6aa09.appspot.com",
messagingSenderId: "188380980204",
appId: "1:188380980204:web:b21ad18362e956afae96c9",
measurementId: "G-TEWHQESB1Y"
};
// Initialize Firebase
firebase.initializeApp(firebaseConfig);
firebase.analytics();
var db = firebase.firestore();
function submit(){
var x = document.getElementById("title").value;
var y = document.getElementById("desc").value;
db.collection("articles").add({
title: x,
body: y,
verified: 0
})
.then(function(docRef) {
console.log("Document written with ID: ", docRef.id);
})
.catch(function(error) {
console.error("Error adding document: ", error);
});
alert("Thank you for submitting a response!");
}
</script>
</body>
</html>