4
Let us try to convert Extra info field to Why reg field.
edit /register.php file and add:
$bio = isset($_POST['bio']) ? trim($myts->stripSlashesGPC($_POST['bio'])) : '';
before:
$url = isset($_POST['url']) ? trim($myts->stripSlashesGPC($_POST['url'])) : '';
and add:
<input type='hidden' name='bio' value='".$myts->htmlSpecialChars($bio)."' />
before:
<input type='hidden' name='url' value='".$myts->htmlSpecialChars($url)."' />
and add:
$newuser->setVar('bio', $bio, true);
after:
$newuser->setVar('email', $email, true);
Now edit /include/registerform.php file and add:
$reg_form->addElement(new XoopsFormTextarea(_US_EXTRAINFO, "bio", $myts->htmlSpecialChars($bio)), true);
before:
$reg_form->addElement(new XoopsFormText(_US_WEBSITE, "url", 25, 255, $myts->htmlSpecialChars($url)));
Demo:Edit /language/english/user.php file and replace:
define('_US_EXTRAINFO','Extra Info');
with:
define('_US_EXTRAINFO','Why Reg ?');