63a0529b21bfd97a4ef395e8d3d3f513526357c6
bernd Stub für dns-Admin-Interface

bernd authored 15 years ago

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>';
bernd eliminate .php extensions f...

bernd authored 15 years ago

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";
bernd Stub für dns-Admin-Interface

bernd authored 15 years ago

35) }
36) $output .= '</table><br />
37) 
bernd eliminate .php extensions f...

bernd authored 15 years ago

38) <p>'.internal_link('dyndns_edit', 'Neuen DynDNS-Account anlegen').'</p>';