1
Dubird
make form fields required
  • 2005/2/5 19:43

  • Dubird

  • Just popping in

  • Posts: 12

  • Since: 2004/1/21


how can i make certian form fields required for registration? i don't need all of them, but i want to make name and address requried to register.

2
wtravel
Re: make form fields required

Hi,

Have a look at the file:
include/registerform.php

As an example look for the line:
$reg_form->addElement(new XoopsFormText(_US_NICKNAME, "uname", $uname_size, $uname_size, $uname), true);

The last part adds the required functionality:
Quote:
), true);


So if you would add:
$reg_form->addElement(new XoopsFormText(_US_REALNAME, "realname", 50, 100, $realname), true);

you would add a required textfield "Real name".

Best wishes,

Martijn

3
Dubird
Re: make form fields required
  • 2005/2/9 6:25

  • Dubird

  • Just popping in

  • Posts: 12

  • Since: 2004/1/21


do i need to modify the table manually then?

Login

Who's Online

420 user(s) are online (60 user(s) are browsing Support Forums)


Members: 0


Guests: 420


more...

Donat-O-Meter

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

Latest GitHub Commits