Beispiel #1
0
 public function getForm()
 {
     $langid = Common::getPostString('langid', GWF_Language::getEnglish()->getID());
     require_once GWF_CORE_PATH . 'module/Category/GWF_CategorySelect.php';
     //key => array(TYPE, default, text, classname)
     //		GWF_Language::setShowSupported(true);
     $data = array('langid' => array(GWF_Form::SELECT, GWF_LangSelect::single(GWF_Language::SUPPORTED, 'langid', $langid), $this->module->lang('th_langid')), 'catid' => array(GWF_Form::SELECT, GWF_CategorySelect::single('catid', Common::getPostString('catid', '1'), 0), $this->module->lang('th_category')), 'title' => array(GWF_Form::STRING, '', $this->module->lang('th_title')), 'message' => array(GWF_Form::MESSAGE, '', $this->module->lang('th_message')), 'div1' => array(GWF_Form::DIVIDER), 'div2' => array(GWF_Form::DIVIDER), 'preview' => array(GWF_Form::SUBMIT, $this->module->lang('btn_preview'), ''), 'add' => array(GWF_Form::SUBMIT, $this->module->lang('btn_add'), ''));
     return new GWF_Form($this, $data);
 }
Beispiel #2
0
 public function validate_cat($m, $arg)
 {
     return GWF_CategorySelect::validateCat($arg, true);
 }