1
Ruddle
User (Edit Profile) Form Question
  • 2003/12/3 16:44

  • Ruddle

  • Just popping in

  • Posts: 61

  • Since: 2003/11/10


Can anyone tell me where the field size limits are placed on the User (edit profile) form? Both as an admin and as an end user.

For example when trying to enter more than 15 characters in the ICQ field of the user form, you receive an error.

HISTORY: I have taken the user form and altered it abit to accept information like address, phone, etc. I have not altered the db table, so in essence I am "mapping" the values to the old db columns... i.e. Address to ICQ, etc. The problem is the ICQ field has a 15 character entry limit. Where is this validation being applied?

I have changed the column size already in the table.

Any help would be greatly appreciated!

Rick

2
CBlue
Re: User (Edit Profile) Form Question

The files dealing with the user pages are:

register.php, user.php, userinfo.php and edituser.php in the root directory.

The only way I know to change the character limit size for text fields for the user pages is to do it through the database in myphpadmin.




3
hsalazar
Re: User (Edit Profile) Form Question
  • 2003/12/3 17:04

  • hsalazar

  • Just popping in

  • Posts: 78

  • Since: 2003/2/6 1


Rick:

You probably already fixed, but in case it has eluded you, look for line 157 in edituser.php:

$icq_text = new XoopsFormText(_US_ICQ, 'user_icq', 15, 15, $xoopsUser->getVar('user_icq', 'E'));

Change both 15 values as needed; the first one containes the $size variable; the second, $maxlength.

Cheers.

4
Ruddle
Re: User (Edit Profile) Form Question
  • 2003/12/3 17:38

  • Ruddle

  • Just popping in

  • Posts: 61

  • Since: 2003/11/10


Thanks for the quick response. I am fortuneate to have a UNIX guru here at work that helped me with a find statement. I was able to search all XOOPS files for the term ICQ. The "mysterious" file that contains the character limit was:

./kernel/user.php

The line:

$this->initVar('user_icq', XOBJ_DTYPE_TXTBOX, null, false, 15);

Just in case anyone else is looking for the information

I did edit the other files you mentioned first. They limit the max entry on the fields but there was something behind the scenes limiting the insert into the table.

For anyone who isn't that up on command line syntax, the following find statement ws helpful:

find . -type f | xargs grep -i "search string"

Thanks again!!

Rick

5
Ruddle
Re: User (Edit Profile) Form Question
  • 2003/12/3 17:48

  • Ruddle

  • Just popping in

  • Posts: 61

  • Since: 2003/11/10


Here's another question though...

I have the member's module to automatically display all members. For a member info list.

I have refined the colum display of the table a bit but am having difficulty in finding where the file is getting it's values from.

As I mentioned before, I am using the original table columns to hold the new values (i.e. in the xoops_users table, user_from now holds the user's phone number.)

The search results template (/modules/xoopsmembers/templates/xoopsmembers_searchresults.html) plugs in a value: <{$users[i].website}>. How would I grab the value for location? I tried <{$users[i].location}> and <{$users[i].user_from}> but nothing has worked.

This must be being mapped in a secondary file.

Any ideas??

Thanks,
Rick

6
CBlue
Re: User (Edit Profile) Form Question

Have you taken a look at the index.php file in the modules/xoopsmembers folder?

7
Ruddle
Re: User (Edit Profile) Form Question
  • 2003/12/3 19:09

  • Ruddle

  • Just popping in

  • Posts: 61

  • Since: 2003/11/10


Hey, that did it! I kind of disregard index files as there are so many of them in XOOPS directories (index.html files).

I had to assign a variable:

$userdata['phone'] = $foundusers[$j]->getVar("user_from");

worked great!

Thanks for the direction!

Rick

8
CBlue
Re: User (Edit Profile) Form Question

You're welcome Rick! I'm glad I was able to help!

Login

Who's Online

154 user(s) are online (88 user(s) are browsing Support Forums)


Members: 0


Guests: 154


more...

Donat-O-Meter

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

Latest GitHub Commits