1
slyss
Add more fields in registation form
  • 2006/4/11 10:10

  • slyss

  • Quite a regular

  • Posts: 343

  • Since: 2006/1/26


hi everybody

i use photo + profile hack by m0nty and i want to add more fields in form registration.. in include/registerform.php i have write the code below and when a user go to register.php can see the right field but THE TEXT (in the below fields) DON'T REGISTER and when users go to userinfo.php there is nothing in the below fields...

where i be mistaken ?
"graphically" is all ok in register.php but in reality fields don't are register really.

[sorry for my english]

thank you


$reg_form->addElement(new XoopsFormText(_US_OCCUPATION"user_occ"65255$myts->htmlSpecialChars($user_occ)));

$reg_form->addElement(new XoopsFormText(_US_INTEREST"user_intrest"65255$myts->htmlSpecialChars($user_intrest)));

$reg_form->addElement(new XoopsFormText(_US_EXTRAINFO"bio"65255$myts->htmlSpecialChars($bio)));

$reg_form->addElement(new XoopsFormSelectTimezone(_US_TIMEZONE"timezone_offset"$tzselected));

$reg_form->addElement(new XoopsFormText(_US_LOVE"user_love"65255$myts->htmlSpecialChars($user_love)));

$reg_form->addElement(new XoopsFormText(_US_NOLOVE"user_nolove"3060$myts->htmlSpecialChars($user_nolove)));
[size=x-large]2008 Xoops Book[/size]

2
davidthomas1
Re: Add more fields in registation form

The form fields you added won't be saved into the database.

You'd need to add new fields into the DB table and edit the SQL somewhere.

Quite a complicated hack.

However, the XOOPS 2.2.x series include the 'extended profiles' module that allows you to add custom fields to the registration form.

But that series is less stable than the 2.0.x series.

When the new XOOPS version comes out, it will probably support extended profiles.

So, either you could:

1) try some more code hacking (backup first!)
2) try XOOPS 2.2.x
3) wait for the new XOOPS version.
みんなちがってみんないい。

XOOPS 2.0.13.2

3
DIDI5
Re: Add more fields in registation form
  • 2006/4/12 6:23

  • DIDI5

  • Just popping in

  • Posts: 36

  • Since: 2006/3/24


Yes quite some work in there.

You can add as many fields as you wish to the registration form.

first try take a look at the following..
1.....kernel/user.php
2...system/admin/findusers/main.php
3...system/admin/users/main.php
4./edituser.php
5.class/modulehandler.php
6.class/xoopscomment.php.
7.system/admin/finduser.php
8.system/users/main.php/
9.dont forget you database as requested above, to add the new corresponding fields, otherwise there will be no where to write the new added info.
10.the corressponding templates to display the new fields/ info..
11.the language to define.

if you have installed xoopsmembers module then.. /index.php
((this from what i know about the older version --2.0.9XX ..the latest i have no idea))

4
slyss
Re: Add more fields in registation form
  • 2006/4/12 8:53

  • slyss

  • Quite a regular

  • Posts: 343

  • Since: 2006/1/26


Quote:

davidthomas1 wrote:
The form fields you added won't be saved into the database.

You'd need to add new fields into the DB table and edit the SQL somewhere.

Quite a complicated hack.

However, the XOOPS 2.2.x series include the 'extended profiles' module that allows you to add custom fields to the registration form.

But that series is less stable than the 2.0.x series.

When the new XOOPS version comes out, it will probably support extended profiles.

So, either you could:

1) try some more code hacking (backup first!)
2) try XOOPS 2.2.x
3) wait for the new XOOPS version.


you don't understand because this fields there are already into the DB table because in my site i have photo + profile hack by m0nty...

in fact, if you are a user of my site and you go into your account you can add/modify this field.

then my problem is only one: give possibility at my users of add this field also in the registration form and not only in edituser.php

my problem is: this field don't add into db!... where i be mistaken ?

thanks a lot at all...
[size=x-large]2008 Xoops Book[/size]

5
davidthomas1
Re: Add more fields in registation form

Sorry, I don't know about Monty's profile hack - never used it.

Perhaps someone else can help more.
みんなちがってみんないい。

XOOPS 2.0.13.2

6
adrock
Re: Add more fields in registation form
  • 2006/4/12 13:28

  • adrock

  • Quite a regular

  • Posts: 291

  • Since: 2004/12/7


Review this information:
https://xoops.org/modules/news/article.php?storyid=2353

If you have changed the names of the fields that monty included, then you only need to change the language defines so that they display the correct info.

If you have added new form elements to the registration form, then you will have to add to the sql files that are included and be sure that the new tables are created in your database before the site will record the information to it. As well as making sure that each page that would call or use those tables has the information added to them as well.

Happy Xoopsing!
Affordable Web Hosting - Family - Fun!...and not always in that order!

7
slyss
Re: Add more fields in registation form
  • 2006/4/12 16:08

  • slyss

  • Quite a regular

  • Posts: 343

  • Since: 2006/1/26


mmmmmmmmm

i won't change any name of field... i want only to do possibility insert more field at time of registration and not only after registration...

help m0nty
[size=x-large]2008 Xoops Book[/size]

Login

Who's Online

404 user(s) are online (290 user(s) are browsing Support Forums)


Members: 0


Guests: 404


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