Changeset 230

Show
Ignore:
Timestamp:
12/10/07 10:22:11 (1 year ago)
Author:
shupp
Message:

get find domain working - fix typo in form action url

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Framework/Module/Main/Find.php

    r229 r230  
    2222            return $this->find(); 
    2323        } 
     24        $this->setData('findForm', $this->findForm()->toHtml());     
     25        $domain = $form->getElementValue('domain'); 
     26        $this->setData('domain', $domain); 
     27 
     28        $result = $this->user->findDomain($domain); 
     29        if ($result == null) { 
     30            $this->setData('message', _('Error: does not exist')); 
     31        } else { 
     32            $this->setData('found', 1); 
     33            $this->setData('delete_url', "./?module=Domains&event=delDomain&domain=$domain"); 
     34            $this->setData('edit_url', "./?module=Domains&class=Menu&domain=$domain"); 
     35        } 
    2436        // Display find form 
    2537        $this->tplFile = 'find.tpl'; 
     
    2840    private function findForm() 
    2941    { 
    30         $form = new HTML_QuickForm('formFind', 'post', './?module=Main&class=Findevent=findNow'); 
     42        $form = new HTML_QuickForm('formFind', 'post', './?module=Main&class=Find&event=findNow'); 
    3143 
    3244        $form->addElement('text', 'domain', _('Domain')); 
  • trunk/Framework/Module/Main/Templates/Default/find.tpl

    r229 r230  
    88{$findForm} 
    99<br /> 
     10{if $found} 
     11<br /> 
     12<a href="{$delete_url}">delete "{$domain}"</a> | <a href="{$edit_url}">edit "{$domain}"</a> 
     13<br /> 
     14<br /> 
     15{/if} 
    1016<a href="./?module=Main">{$LANG_Main_Menu}</a> 
    1117</div>