<?php

Goweb::loadClass('Goweb_Form');

/**
 * Goweb Sitemanager 5 Framework
 * @version    5.0.0
 * @category   Frontoffice
 * @package    Cms
 * @subpackage Form
 * @author     I&D <dev@goweb.pt>, Pedro Pinto <ppinto@goweb.pt>
 * @copyright  2009 (c) Goweb (http://www.goweb.pt)
*/
class Form_Pesquisa extends Goweb_Form {

    /**
     * Construtor da classe
    */
    public function __construct() {
        parent::__construct('Form_Pesquisa', '/cms/resultado_pesquisa/', 'POST');
    }
    
    /**
     * Metodo obrigatorio as classes herdeiras do Goweb_Form
    */
    protected function _setup() {
        $this->palavra = $this->Text();
        $this->palavra->setLabel(translate('Pesquisa'));
        $this->palavra->class = 'input'; 
        /*$this->palavra->setValue(translate('Pesquisa'));
        $this->palavra->setAttrib('onblur','if (this.value == "") this.value="' . translate('Pesquisa') . '";');
        $this->palavra->setAttrib('onfocus','if (this.value == "' . translate('Pesquisa') . '") this.value="";');*/
        
        $this->submit = $this->Submit();
        $this->submit->setValue(translate('Pesquisar'));
        $this->submit->class = 'submit';
    }

}