-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsupport_form.php
More file actions
47 lines (39 loc) · 1.37 KB
/
support_form.php
File metadata and controls
47 lines (39 loc) · 1.37 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
<?php
require('top_file.php');
?>
<?
print "support form has been disabled.\n";
exit;
include "db.php";
if($_REQUEST[action] == 'submit') {
if(strlen($_REQUEST[message]) < 5 || strlen($_REQUEST[email]) < 5) {
print "Fehler: Keine Nachricht eingegeben.\n";
} else if(checkInjection($_REQUEST[email])) {
print "Error: invalid input\n";
exit; // asure conformity to other forms with same error message (no closing body and html tag).
} else {
if(mail("rha_alumniSupport@disconnect.ch", "Alumni DB support mail", $_REQUEST[message], "From: $_REQUEST[email]\nCc: david.b_alumniSupport@disconnect.ch")) {
print "Deine Anfrage wurde abgeschickt.";
} else {
print "Interner Systemfehler. Anfrage konnte nicht übermittelt werden.";
}
}
print "</div></div><div id=\"background_footer\"></div></body></html>\n";
exit;
}
print"
<h3>Support-Anfrage erfassen</h3>
Hier kannst Du den Entwickler dieser Datenbank um Hilfe bitten,
wenn Du feststeckst, oder etwas nicht geht.
<p>
<form action=\"$PHP_SELF\" method=\"post\">"
?>
<table border=0>
<tr><td>Deine Emailadresse:</td><td><input name="email" size=50></td></tr>
<tr valign="top"><td>Anfrage:</td><td><textarea name="message" rows=15 cols=50></textarea></td></tr>
<tr><td> </td><td><input type="submit" value="Abschicken"></td></tr>
</table>
<input type="hidden" name="action" value="submit">
</form>
</body>
</html>