Browse code

Zeige IPv6-Adresse beim DynDNS

Bernd Wurst authored on24/01/2019 12:34:21
Showing1 changed files
... ...
@@ -48,7 +48,14 @@ foreach ($dyndns as $entry) {
48 48
     } else {
49 49
         $method = '<em>keine</em>';
50 50
     }
51
-    output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', icon_delete("Account löschen"), "id={$entry['id']}&type=dyndns&action=delete").' '.internal_link('dyndns_hostnames', other_icon("world_link.png", "Hostnames verwalten"), "id={$entry['id']}")."</td></tr>\n");
51
+    $address = $entry['address'];
52
+    if ($address == '') {
53
+        $address = "<em>keine IPv4-Adresse</em>";
54
+    }
55
+    if ($entry['ipv6']) {
56
+        $address .= " / ".$entry['ipv6'];
57
+    }
58
+    output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$address}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', icon_delete("Account löschen"), "id={$entry['id']}&type=dyndns&action=delete").' '.internal_link('dyndns_hostnames', other_icon("world_link.png", "Hostnames verwalten"), "id={$entry['id']}")."</td></tr>\n");
52 59
 }
53 60
 output('</table>');
54 61
 
Browse code

Fix coding style with php-cs-checker, see https://cs.sensiolabs.org/

Hanno authored on26/06/2018 13:58:19
Showing1 changed files
... ...
@@ -8,7 +8,7 @@ Written 2008-2018 by schokokeks.org Hosting, namely
8 8
 
9 9
 To the extent possible under law, the author(s) have dedicated all copyright and related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty.
10 10
 
11
-You should have received a copy of the CC0 Public Domain Dedication along with this software. If not, see 
11
+You should have received a copy of the CC0 Public Domain Dedication along with this software. If not, see
12 12
 http://creativecommons.org/publicdomain/zero/1.0/
13 13
 
14 14
 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.
... ...
@@ -31,25 +31,25 @@ output("<p>Hier sehen Sie eine Übersicht über die angelegten DynDNS-Accounts.<
31 31
 output('<table><tr><th>Kürzel</th><th>Methode</th><th>aktuelle IP</th><th>letztes Update</th><th>&#160;</th></tr>
32 32
 ');
33 33
 
34
-foreach ($dyndns AS $entry) {
35
-  $handle = $entry['handle'];
36
-  if (!$handle)
37
-    $handle = '<em>undefiniert</em>';
38
-  $method = '';
39
-  if ($entry['sshkey'])
40
-    if ($entry['password'])
41
-      $method = 'SSH, HTTP';
42
-    else
43
-      $method = 'SSH';
44
-  else
45
-    if ($entry['password'])
46
-      $method = 'HTTP';
47
-    else
48
-      $method = '<em>keine</em>';
49
-  output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', icon_delete("Account löschen"), "id={$entry['id']}&type=dyndns&action=delete").' '.internal_link('dyndns_hostnames', other_icon("world_link.png", "Hostnames verwalten"), "id={$entry['id']}")."</td></tr>\n");
34
+foreach ($dyndns as $entry) {
35
+    $handle = $entry['handle'];
36
+    if (!$handle) {
37
+        $handle = '<em>undefiniert</em>';
38
+    }
39
+    $method = '';
40
+    if ($entry['sshkey']) {
41
+        if ($entry['password']) {
42
+            $method = 'SSH, HTTP';
43
+        } else {
44
+            $method = 'SSH';
45
+        }
46
+    } elseif ($entry['password']) {
47
+        $method = 'HTTP';
48
+    } else {
49
+        $method = '<em>keine</em>';
50
+    }
51
+    output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', icon_delete("Account löschen"), "id={$entry['id']}&type=dyndns&action=delete").' '.internal_link('dyndns_hostnames', other_icon("world_link.png", "Hostnames verwalten"), "id={$entry['id']}")."</td></tr>\n");
50 52
 }
51 53
 output('</table>');
52 54
 
53 55
 addnew('dyndns_edit', 'Neuen DynDNS-Account anlegen');
54
-
55
-?>
Browse code

Copyright year update

Bernd Wurst authored on13/01/2018 06:07:05
Showing1 changed files
... ...
@@ -2,7 +2,7 @@
2 2
 /*
3 3
 This file belongs to the Webinterface of schokokeks.org Hosting
4 4
 
5
-Written 2008-2014 by schokokeks.org Hosting, namely
5
+Written 2008-2018 by schokokeks.org Hosting, namely
6 6
   Bernd Wurst <bernd@schokokeks.org>
7 7
   Hanno Böck <hanno@schokokeks.org>
8 8
 
Browse code

Erzeuge nicht einen DynDNS-Hostname unser der Masterdomain sondern frage gleich vom User ab welcher Hostname verwendet werden soll

Bernd Wurst authored on01/07/2016 10:19:58
Showing1 changed files
... ...
@@ -16,6 +16,7 @@ Nevertheless, in case you use a significant part of this code, we ask (but not r
16 16
 
17 17
 require_once('inc/base.php');
18 18
 require_once('inc/security.php');
19
+require_once('inc/icons.php');
19 20
 
20 21
 require_role(ROLE_SYSTEMUSER);
21 22
 
... ...
@@ -45,7 +46,7 @@ foreach ($dyndns AS $entry) {
45 46
       $method = 'HTTP';
46 47
     else
47 48
       $method = '<em>keine</em>';
48
-  output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n");
49
+  output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', icon_delete("Account löschen"), "id={$entry['id']}&type=dyndns&action=delete").' '.internal_link('dyndns_hostnames', other_icon("world_link.png", "Hostnames verwalten"), "id={$entry['id']}")."</td></tr>\n");
49 50
 }
50 51
 output('</table>');
51 52
 
Browse code

Lizenzinfos in eigenes Modul ausgelagert und Copyright auf 2014 angepasst

Bernd Wurst authored on08/02/2014 05:45:07
Showing1 changed files
... ...
@@ -2,7 +2,7 @@
2 2
 /*
3 3
 This file belongs to the Webinterface of schokokeks.org Hosting
4 4
 
5
-Written 2008-2013 by schokokeks.org Hosting, namely
5
+Written 2008-2014 by schokokeks.org Hosting, namely
6 6
   Bernd Wurst <bernd@schokokeks.org>
7 7
   Hanno Böck <hanno@schokokeks.org>
8 8
 
Browse code

Updated copyright notice (2012 => 2013)

Bernd Wurst authored on19/01/2013 10:49:50
Showing1 changed files
... ...
@@ -2,7 +2,7 @@
2 2
 /*
3 3
 This file belongs to the Webinterface of schokokeks.org Hosting
4 4
 
5
-Written 2008-2012 by schokokeks.org Hosting, namely
5
+Written 2008-2013 by schokokeks.org Hosting, namely
6 6
   Bernd Wurst <bernd@schokokeks.org>
7 7
   Hanno Böck <hanno@schokokeks.org>
8 8
 
Browse code

Added license tags for CC0, README and COPYING

Bernd Wurst authored on11/03/2012 15:40:04
Showing1 changed files
... ...
@@ -1,4 +1,18 @@
1 1
 <?php
2
+/*
3
+This file belongs to the Webinterface of schokokeks.org Hosting
4
+
5
+Written 2008-2012 by schokokeks.org Hosting, namely
6
+  Bernd Wurst <bernd@schokokeks.org>
7
+  Hanno Böck <hanno@schokokeks.org>
8
+
9
+To the extent possible under law, the author(s) have dedicated all copyright and related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty.
10
+
11
+You should have received a copy of the CC0 Public Domain Dedication along with this software. If not, see 
12
+http://creativecommons.org/publicdomain/zero/1.0/
13
+
14
+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.
15
+*/
2 16
 
3 17
 require_once('inc/base.php');
4 18
 require_once('inc/security.php');
Browse code

Benutze überall title() statt output("<h3>...</h3>")

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1812 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on18/09/2010 13:35:15
Showing1 changed files
... ...
@@ -10,11 +10,11 @@ require_once('dnsinclude.php');
10 10
 
11 11
 $dyndns = get_dyndns_accounts();
12 12
 
13
-$output .= '<h3>DynDNS-Accounts</h3>
14
-<p>Hier sehen Sie eine Übersicht über die angelegten DynDNS-Accounts.</p>';
13
+title("DynDNS-Accounts");
14
+output("<p>Hier sehen Sie eine Übersicht über die angelegten DynDNS-Accounts.</p>");
15 15
 
16
-$output .= '<table><tr><th>Kürzel</th><th>Methode</th><th>aktuelle IP</th><th>letztes Update</th><th>&#160;</th></tr>
17
-';
16
+output('<table><tr><th>Kürzel</th><th>Methode</th><th>aktuelle IP</th><th>letztes Update</th><th>&#160;</th></tr>
17
+');
18 18
 
19 19
 foreach ($dyndns AS $entry) {
20 20
   $handle = $entry['handle'];
... ...
@@ -31,9 +31,9 @@ foreach ($dyndns AS $entry) {
31 31
       $method = 'HTTP';
32 32
     else
33 33
       $method = '<em>keine</em>';
34
-  $output .= "<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n";
34
+  output("<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n");
35 35
 }
36
-$output .= '</table>';
36
+output('</table>');
37 37
 
38 38
 addnew('dyndns_edit', 'Neuen DynDNS-Account anlegen');
39 39
 
Browse code

Erlaube *useraccounts* das edtieren von DNS-records

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1731 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on06/05/2010 14:49:17
Showing1 changed files
... ...
@@ -3,7 +3,7 @@
3 3
 require_once('inc/base.php');
4 4
 require_once('inc/security.php');
5 5
 
6
-require_role(ROLE_CUSTOMER);
6
+require_role(ROLE_SYSTEMUSER);
7 7
 
8 8
 require_once('dnsinclude.php');
9 9
 
Browse code

addnew() eingeführt

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1424 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on20/07/2009 17:43:47
Showing1 changed files
... ...
@@ -33,8 +33,8 @@ foreach ($dyndns AS $entry) {
33 33
       $method = '<em>keine</em>';
34 34
   $output .= "<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n";
35 35
 }
36
-$output .= '</table><br />
36
+$output .= '</table>';
37 37
 
38
-<p>'.internal_link('dyndns_edit', 'Neuen DynDNS-Account anlegen').'</p>';
38
+addnew('dyndns_edit', 'Neuen DynDNS-Account anlegen');
39 39
 
40 40
 ?>
Browse code

eliminate .php extensions for URLs

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1128 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on08/08/2008 19:32:32
Showing1 changed files
... ...
@@ -31,10 +31,10 @@ foreach ($dyndns AS $entry) {
31 31
       $method = 'HTTP';
32 32
     else
33 33
       $method = '<em>keine</em>';
34
-  $output .= "<tr><td>".internal_link("dyndns_edit.php", $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link("save.php", '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n";
34
+  $output .= "<tr><td>".internal_link('dyndns_edit', $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link('save', '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n";
35 35
 }
36 36
 $output .= '</table><br />
37 37
 
38
-<p>'.internal_link('dyndns_edit.php', 'Neuen DynDNS-Account anlegen').'</p>';
38
+<p>'.internal_link('dyndns_edit', 'Neuen DynDNS-Account anlegen').'</p>';
39 39
 
40 40
 ?>
Browse code

Stub für dns-Admin-Interface

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1127 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on08/08/2008 17:19:03
Showing1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,40 @@
1
+<?php
2
+
3
+require_once('inc/base.php');
4
+require_once('inc/security.php');
5
+
6
+require_role(ROLE_CUSTOMER);
7
+
8
+require_once('dnsinclude.php');
9
+
10
+
11
+$dyndns = get_dyndns_accounts();
12
+
13
+$output .= '<h3>DynDNS-Accounts</h3>
14
+<p>Hier sehen Sie eine Übersicht über die angelegten DynDNS-Accounts.</p>';
15
+
16
+$output .= '<table><tr><th>Kürzel</th><th>Methode</th><th>aktuelle IP</th><th>letztes Update</th><th>&#160;</th></tr>
17
+';
18
+
19
+foreach ($dyndns AS $entry) {
20
+  $handle = $entry['handle'];
21
+  if (!$handle)
22
+    $handle = '<em>undefiniert</em>';
23
+  $method = '';
24
+  if ($entry['sshkey'])
25
+    if ($entry['password'])
26
+      $method = 'SSH, HTTP';
27
+    else
28
+      $method = 'SSH';
29
+  else
30
+    if ($entry['password'])
31
+      $method = 'HTTP';
32
+    else
33
+      $method = '<em>keine</em>';
34
+  $output .= "<tr><td>".internal_link("dyndns_edit.php", $handle, "id={$entry['id']}")."</td><td>{$method}</td><td>{$entry['address']}</td><td>{$entry['lastchange']}</td><td>".internal_link("save.php", '<img src="'.$prefix.'images/delete.png" width="16" height="16" alt="löschen" title="Account löschen" />', "id={$entry['id']}&type=dyndns&action=delete")."</td></tr>\n";
35
+}
36
+$output .= '</table><br />
37
+
38
+<p>'.internal_link('dyndns_edit.php', 'Neuen DynDNS-Account anlegen').'</p>';
39
+
40
+?>