-
Notifications
You must be signed in to change notification settings - Fork 0
/
contact.html
188 lines (185 loc) · 5.36 KB
/
contact.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
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no">
<title>Contact – Tumasik.be</title>
<meta name="author" content="Christophe Vanhoutte">
<style>
body{
padding:1em;
font-family: 'Roboto', sans-serif;
-webkit-font-smoothing: antialiased;
}
body,#main{
background-color: #e0e0e0;
color:#404040;
}
h1{
text-align:center;
}
h1,h2{
cursor: default;
}
p.center{
text-align:center;
}
.nostyle{
text-decoration:none;
color:#404040;
}
abbr[title]{
border-bottom:1px dotted;
}
abbr[title]:hover{
cursor:help;
}
button {
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
font-family: Arial;
color: #ffffff;
font-size: 17px;
padding: .5em;
background: #404040;
text-decoration: none;
border: 0;
transition: all 0.5s ease;
}
button:hover {
background: #808080;
text-decoration: none;
cursor:pointer;
}
hr{
width:50%;
float:none;
margin: 2em auto;
}
.alert {
color: #31708f;
background-color: #d9edf7;
border-color: #bce8f1;
margin: 0 10%;
padding: 15px;
margin-bottom: 20px;
border: 1px solid transparent;
border-radius: 4px;
text-align: center;
}
a, a:visited{
color:#3C3C3C;
text-shadow: 0 0 0 transparent,0px -1px 0px #FFF;
margin: .2em;
text-decoration: none;
border-bottom: 1px #989898 solid;
transition: all ease .2s;
}
a:hover{
border-bottom: 1px #CC0000 solid;
}
p {
line-height: 1.5;
}
::selection {
color: #fff;
background: #404040;}
/* contact form reset */
form input,
form select,
form textarea,
form fieldset,
form optgroup,
form label,
.StripeElement {
font-family: inherit;
font-size: 100%;
color: inherit;
border: none;
border-radius: 0;
display: block;
width: 100%;
padding: 0;
margin: 0;
-webkit-appearance: none;
-moz-appearance: none;
}
form label,
form legend {
font-size: 0.825rem;
margin-bottom: 0.5rem;
}
/* border, padding, margin, width */
form input,
form select,
form textarea,
.StripeElement {
box-sizing: border-box;
border: 1px solid rgba(0, 0, 0, 0.2);
background-color: rgba(255, 255, 255, 0.9);
padding: 0.75em 1rem;
margin-bottom: 1.5rem;
}
form input:focus,
form select:focus,
form textarea:focus,
.StripeElement:focus {
background-color: white;
outline-style: solid;
outline-width: thin;
outline-color: gray;
outline-offset: -1px;
}
form [type="text"],
form [type="email"],
.StripeElement {
width: 100%;
}
form [type="button"],
form [type="submit"],
form [type="reset"] {
width: auto;
cursor: pointer;
-webkit-appearance: button;
-moz-appearance: button;
appearance: button;
}
form [type="button"]:focus,
form [type="submit"]:focus,
form [type="reset"]:focus {
outline: none;
}
form select {
text-transform: none;
}
</style>
<link href='//fonts.googleapis.com/css?family=Roboto' rel='stylesheet'>
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body itemscope itemtype="https://schema.org/WebPage">
<a href="https://tumasik.be/" title="Tumasik.be" alt="Tumasik.be" rel="home" class="nostyle"><button>← Tumasik.be</button></a>
<div id="main" itemprop="mainContentOfPage">
<h1>Contact</h1>
<p>
<form id="my-form" action="https://formspree.io/f/mnqevdlq" method="POST">
<fieldset id="fs-frm-inputs">
<label for="full-name">Full Name</label>
<input type="text" name="name" id="full-name" placeholder="Voornaam Achternaam" required="">
<label for="email-address">Email Address</label>
<input type="email" name="_replyto" id="email-address" placeholder="[email protected]" required="">
<label for="message">Message</label>
<textarea rows="5" name="message" id="message" placeholder="Uw bericht hier" required=""></textarea>
<input type="hidden" name="_subject" id="email-subject" value="Tumasik.be - Contact">
</fieldset>
<p id="my-form-status"></p>
<input type="submit" value="Submit">
</form>
</p>
</div>
<script>
var form = document.getElementById("my-form");async function handleSubmit(event) {event.preventDefault();var status = document.getElementById("my-form-status");var data = new FormData(event.target);fetch(event.target.action, { method: form.method, body: data, headers: { 'Accept': 'application/json'}}).then(response => { if (response.ok) { status.innerHTML = "Bedankt, uw bericht werd verzonden."; form.reset() } else { response.json().then(data => { if (Object.hasOwn(data, 'errors')) { status.innerHTML = data["errors"].map(error => error["message"]).join(", ") } else { status.innerHTML = "Oops! There was a problem submitting your form" } })}}).catch(error => { status.innerHTML = "Oops! There was a problem submitting your form"});}form.addEventListener("submit", handleSubmit)</script>
</body>
</html>