1
gwrae
Remove user registraion details
  • 2005/4/15 9:37

  • gwrae

  • Just popping in

  • Posts: 2

  • Since: 2005/4/15


Hi,

I'm fairly new to XOOPS and am using it to support a school website.

As pupils will have the ability to register for the site, I would like to remove the website field as an option during registration. This is to prevent pupils personal details being available through our website.

For the same reasons, I would like to remove a number of fields from the users profile, namely website, ICQ, MSNM, YIM, AIM.

I have read a number of posts regarding adding fields, or changing field names, but cannot find anything on removing them. I am also aware that the next version of XOOPS may have thiis functionality built in.

Thanks in advance,

gwrae

2
m0nty
Re: Remove user registraion details
  • 2005/4/15 10:19

  • m0nty

  • XOOPS is my life!

  • Posts: 3337

  • Since: 2003/10/24


open file edituser.php

find these lines and remove them..

$edituser->setVar('url'formatURL($url));
$edituser->setVar('user_icq'$user_icq);
$edituser->setVar('user_aim'$user_aim);
$edituser->setVar('user_yim'$user_yim);
$edituser->setVar('user_msnm'$user_msnm);

$url_text = new XoopsFormText(_US_WEBSITE'url'30100$xoopsUser->getVar('url''E'));
$form->addElement($url_text);

$icq_text = new XoopsFormText(_US_ICQ'user_icq'1515$xoopsUser->getVar('user_icq''E'));
$aim_text = new XoopsFormText(_US_AIM'user_aim'1818$xoopsUser->getVar('user_aim''E'));
$yim_text = new XoopsFormText(_US_YIM'user_yim'2525$xoopsUser->getVar('user_yim''E'));
$msnm_text = new XoopsFormText(_US_MSNM'user_msnm'30100$xoopsUser->getVar('user_msnm''E'));

$form->addElement($icq_text);
$form->addElement($aim_text);
$form->addElement($yim_text);
$form->addElement($msnm_text);


open userinfo.php

find and remove

$xoopsTpl->assign('lang_website'_US_WEBSITE);
$xoopsTpl->assign('user_websiteurl''.$thisUser->getVar('url''E').'" target="_blank">'.$thisUser->getVar('url').'');

$xoopsTpl->assign('lang_icq'_US_ICQ);
$xoopsTpl->assign('user_icq'$thisUser->getVar('user_icq'));
$xoopsTpl->assign('lang_aim'_US_AIM);
$xoopsTpl->assign('user_aim'$thisUser->getVar('user_aim'));
$xoopsTpl->assign('lang_yim'_US_YIM);
$xoopsTpl->assign('user_yim'$thisUser->getVar('user_yim'));
$xoopsTpl->assign('lang_msnm'_US_MSNM);
$xoopsTpl->assign('user_msnm'$thisUser->getVar('user_msnm'));


open include/registerform.php

find and remove

$url = isset($_POST['url']) ? $myts->makeTboxData4PreviewInForm($_POST['url']) : "";

$reg_form->addElement(new XoopsFormText(_US_WEBSITE"url"25255$url));


open register.php

find and remove

if ( isset($url) && $url != '' ) {
            
$url formatURL($myts->makeTboxData4Preview($url));
            echo 
_US_WEBSITE.": $url";
        }


<
input type='hidden' name='url' value='".$myts->makeTboxData4PreviewInForm($url)."' />


        if ( isset(
$url) && $url!='' ) {
            
$newuser->setVar('url'formatURL($url));
        }


open modules/system/templates/system_userinfo.html

find and remove

<tr>
          <
td class="head"><{$lang_website}>td>
          <
td class="even"><{$user_websiteurl}>td>
        tr>


        <
tr valign="top">
          <
td class="head"><{$lang_icq}>td>
          <
td class="odd"><{$user_icq}>td>
        tr>
        <
tr valign="top">
          <
td class="head"><{$lang_aim}>td>
          <
td class="even"><{$user_aim}>td>
        tr>
        <
tr valign="top">
          <
td class="head"><{$lang_yim}>td>
          <
td class="odd"><{$user_yim}>td>
        tr>
        <
tr valign="top">
          <
td class="head"><{$lang_msnm}>td>
          <
td class="even"><{$user_msnm}>td>
        tr>



then goto admin and then click system then modules and then update the system module..

3
gwrae
Re: Remove user registraion details
  • 2005/4/16 16:42

  • gwrae

  • Just popping in

  • Posts: 2

  • Since: 2005/4/15


Truly amgnificent,

thank you for the help.

gwrae

4
Chappy
Re: Remove user registraion details
  • 2005/4/16 16:54

  • Chappy

  • Friend of XOOPS

  • Posts: 456

  • Since: 2002/12/14


Actually, this would make a nice hack - the ability to add or subtract registration fields and to make them required or optional. I found this an interesting post.

Login

Who's Online

181 user(s) are online (139 user(s) are browsing Support Forums)


Members: 0


Guests: 181


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits