1
Hi! I am using XOOPS version 2.2.3. I have problem when using form validation with xoopsform and smarty template together;
Ok, I have the form like this :
le="color: #000000"><?php $form = new XoopsThemeForm($formTitle, "categoryform", $formAction, "POST"); $form->addElement(new XoopsFormText(_MD_XINVENTORY_CATEGORY_NAME, "catname", 30, 60,$catNameValue),true); $form->assign(&$xoopsTpl);
The form can be rendered through a template but I found that form validation at the "catname" field doesn't work unless I change. ie. It won't warn of empty string.
le="color: #000000"><?php $form->assign(&$xoopsTpl)
to
le="color: #000000"><?php $form->display()
I notice that when using the display() method, a "*" is marked beside the "catname", but there is no such mark when using the
template method.
Any idea ?
Thanks
Cody