28667e96bdcc072a7485ff50021f54f555c59ea3
Bernd Wurst Erzeuge nicht einen DynDNS-...

Bernd Wurst authored 8 years ago

1) <?php
2) /*
3) This file belongs to the Webinterface of schokokeks.org Hosting
4) 
Hanno Böck Change license from CC0 to...

Hanno Böck authored 2 years ago

5) Written by schokokeks.org Hosting, namely
Bernd Wurst Erzeuge nicht einen DynDNS-...

Bernd Wurst authored 8 years ago

6)   Bernd Wurst <bernd@schokokeks.org>
7)   Hanno Böck <hanno@schokokeks.org>
8) 
Hanno Böck Change license from CC0 to...

Hanno Böck authored 2 years ago

9) This code is published under a 0BSD license.
Bernd Wurst Erzeuge nicht einen DynDNS-...

Bernd Wurst authored 8 years ago

10) 
11) Nevertheless, in case you use a significant part of this code, we ask (but not require, see the license) that you keep the authors' names in place and return your changes to the public. We would be especially happy if you tell us what you're going to do with this code.
12) */
13) 
14) require_once('inc/base.php');
15) require_once('inc/debug.php');
16) global $debugmode;
17) require_once('inc/security.php');
18) 
19) require_role(ROLE_SYSTEMUSER);
20) 
21) require_once('dnsinclude.php');
22) 
23) $section = 'dns_dyndns';
24) 
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

25) if (!isset($_REQUEST['id'])) {
26)     system_failure("Keine ID");
27) }
Bernd Wurst Erzeuge nicht einen DynDNS-...

Bernd Wurst authored 8 years ago

28) 
29) $id = (int) $_REQUEST['id'];
30) $record = get_dns_record($id);
31) $dyndns = get_dyndns_account($record['dyndns']);
32) 
33) $sure = user_is_sure();
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

34) if ($sure === null) {
35)     $domain = new Domain((int) $record['domain']);
36)     $fqdn = $domain->fqdn;
37)     if ($record['hostname']) {
38)         $fqdn = $record['hostname'].'.'.$fqdn;
39)     }
40)     are_you_sure("action=delete&id={$id}", "Möchten Sie den Hostname ".$fqdn." für den DynDNS-Account {$dyndns['handle']} wirklich löschen?");
41) } elseif ($sure === true) {
Hanno verbleibende syntaxfehler u...

Hanno authored 6 years ago

42)     delete_dns_record($id);
Hanno Böck Fix not operator (!) spaces

Hanno Böck authored 1 year ago

43)     if (!$debugmode) {
Hanno verbleibende syntaxfehler u...

Hanno authored 6 years ago

44)         header("Location: dyndns_hostnames?id=".$dyndns['id']);
45)     }
46) } elseif ($sure === false) {
Hanno Böck Fix not operator (!) spaces

Hanno Böck authored 1 year ago

47)     if (!$debugmode) {