Ignore:
Timestamp:
02/27/2006 06:39:19 AM (6 years ago)
Author:
cirrus
Message:

Add: Delete buttons for nameserver view, range view, dnszone view and user.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/pages/hostmaster/hostmaster_dnsnameserver.php

    r118 r148  
    136136        function output() { 
    137137                if ($_SERVER['REQUEST_METHOD'] == 'POST' && method_exists($this, 'output_onpost_'.$_POST['form_name'])) return call_user_func(array($this, 'output_onpost_'.$_POST['form_name'])); 
    138                 global $construct; 
     138                global $construct,$db,$main; 
     139                if(get('action') === "delete") 
     140                { 
     141                        $ret = $db->del("dns_nameservers", "id = '".get('nameserver')."'"); 
     142                        if ($ret) { 
     143                                $main->message->set_fromlang('info', 'delete_success', makelink(array("page" => "hostmaster", "subpage" => "dnsnameservers"))); 
     144                        } else { 
     145                                $main->message->set_fromlang('error', 'generic');                
     146                        } 
     147                        return ; 
     148                } 
    139149                $this->tpl['form_nameserver'] = $construct->form($this->form_nameserver(), __FILE__); 
    140150                $this->tpl['table_node_info'] = $construct->table($this->table_node_info(), __FILE__); 
     
    142152                $this->tpl['table_links'] = $construct->table($this->table_links(), __FILE__); 
    143153                $this->tpl['table_dns'] = $construct->table($this->table_dns(), __FILE__); 
     154                $this->tpl['link_nameserver_delete'] = makelink (array("action" => "delete"),TRUE); 
    144155                return template($this->tpl, __FILE__); 
    145156        } 
Note: See TracChangeset for help on using the changeset viewer.