My "HOW TO" extended fields in registration. No EXT needed.
Moderator: General Support Moderators
Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
-
- Joomla! Apprentice
- Posts: 7
- Joined: Fri Apr 03, 2009 11:21 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
For some reason it is now passing the information I created in the new field to the database. Any help would be greatly appreciated.
-
- Joomla! Ace
- Posts: 1284
- Joined: Thu Jul 10, 2008 2:51 am
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
With no frame of reference here, how do you expect help?gametopius wrote:For some reason it is now passing the information I created in the new field to the database. Any help would be greatly appreciated.
You have added fields to the registration form and they are storing in the database .... what do you need help with specifically?
-
- Joomla! Apprentice
- Posts: 7
- Joined: Fri Apr 03, 2009 11:21 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
jnodwell wrote:With no frame of reference here, how do you expect help?gametopius wrote:For some reason it is now passing the information I created in the new field to the database. Any help would be greatly appreciated.
You have added fields to the registration form and they are storing in the database .... what do you need help with specifically?
I have added a Last Name field to the registration page, and have modified all of the php files listed. Yet when a user enters in their Last Name it does not show that information in the database, or when I look at their account in the back end. So it seems that information is not getting passed on.
-
- Joomla! Ace
- Posts: 1284
- Joined: Thu Jul 10, 2008 2:51 am
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
Did you include the field in the insert statement to create a new user?
-
- Joomla! Apprentice
- Posts: 7
- Joined: Fri Apr 03, 2009 11:21 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
In what file is the insert statement located?jnodwell wrote:Did you include the field in the insert statement to create a new user?
-
- Joomla! Enthusiast
- Posts: 248
- Joined: Tue Nov 14, 2006 3:29 am
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
This would be handy if it didn't modify core files. ;)
-
- Joomla! Apprentice
- Posts: 5
- Joined: Sun Apr 26, 2009 1:53 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hello jtullous,
I posted a thread on how to add additional columns, feed them and show their data on webpage. Then, I saw your thread and using the method you told, my issue was resolved seamlessly ........... Thanks!
However, a new issue is to be addressed. I have created additional fields in the tables of sections, content and categories and have also added corresponding form fields and variables to handle them.
Now, when I edit an article, category or section, the data additional that I fed is not loaded in Edit mode. Also, when I make a copy of an article, the copied article does not have the additional data and the fields remain empty in the DB table.
Can you please tell me how to handle these 2 problems?
Thanks.
I posted a thread on how to add additional columns, feed them and show their data on webpage. Then, I saw your thread and using the method you told, my issue was resolved seamlessly ........... Thanks!
However, a new issue is to be addressed. I have created additional fields in the tables of sections, content and categories and have also added corresponding form fields and variables to handle them.
Now, when I edit an article, category or section, the data additional that I fed is not loaded in Edit mode. Also, when I make a copy of an article, the copied article does not have the additional data and the fields remain empty in the DB table.
Can you please tell me how to handle these 2 problems?
Thanks.
-
- Joomla! Intern
- Posts: 72
- Joined: Sat May 02, 2009 10:13 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Dear guys, this is realy useful discussion.
can any one help me in how can i create a user group? and make a two diffrent registration forms one for each user group.
I know that it can be in one registraters/users form and registrant choose the group from a drop down menu, but the next fields will depened one the group he will choose so i think it will be complicated to be done in one form.
Thanks
can any one help me in how can i create a user group? and make a two diffrent registration forms one for each user group.
I know that it can be in one registraters/users form and registrant choose the group from a drop down menu, but the next fields will depened one the group he will choose so i think it will be complicated to be done in one form.
Thanks
-
- Joomla! Intern
- Posts: 72
- Joined: Sat May 02, 2009 10:13 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Dear guys,
I want to make a new registration form, so i have two (the original one and the new one) and i will create its fields it is easy as i will link it to the same table just will add some fields in the sencond form.
if this will be difficult, i want a drop down menu in the registration form, so according to user choice the input field appear or change.
Hope someone could help.
Thx,
I want to make a new registration form, so i have two (the original one and the new one) and i will create its fields it is easy as i will link it to the same table just will add some fields in the sencond form.
if this will be difficult, i want a drop down menu in the registration form, so according to user choice the input field appear or change.
Hope someone could help.
Thx,
-
- Joomla! Enthusiast
- Posts: 127
- Joined: Fri Oct 10, 2008 11:01 am
- Location: Greece
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
HI i am a little confused ...
can someone describe the steps for inserting two drop downfields in registration form ?
age and sex are the fields
can someone describe the steps for inserting two drop downfields in registration form ?
age and sex are the fields
Web Design - Internet Consultants
Web Builders
Web Builders
-
- Joomla! Fledgling
- Posts: 3
- Joined: Tue Jun 16, 2009 2:18 pm
Re: My "HOW TO" extended fields in registration. No EXT needed.
I have used this excellent answer for a checkbox, but if the checkbox is unticked ie Null the msg doesn't display any value. If it's ticked then it displays 1. How can I make it display 0 if the checkbox is unticked?
-
- Joomla! Apprentice
- Posts: 17
- Joined: Wed Aug 19, 2009 7:29 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hi People
I have read this post and I have done the following
1. I added the feild to the jos_users table using the code
2. I also edited the user.php in libraries/joomla/database/table/user.php
I added a variable var $address = null; under the peice of code var $username = null;
3. I also edited the files components/com_user/views/register/tmpl/default.php
and added the peice of code:
and in components/com_user/views/user/tmpl/form.php id added the code for address feild as
Now my the newly added feilds do get displayed in the registration form but when I click the register button the values are not stored in my database
I am using Joomla 1.5.6 and Xampp
I tried using UserMeta is works fine but it does not get aligned with feilds already there in the form previously. no documentation is available on the same.
So can anyone help me ??
I have read this post and I have done the following
1. I added the feild to the jos_users table using the code
Code: Select all
ALTER TABLE jos_users ADD address VARCHAR (100) NOt NULL ;
I added a variable var $address = null; under the peice of code var $username = null;
3. I also edited the files components/com_user/views/register/tmpl/default.php
and added the peice of code:
Code: Select all
<tr>
<td width="30%" height="40">
<label id="addressmsg" for="address"><?php echo JText::_( 'Address' ); ?>: </label> </td>
<td>
<input type="text" name="address" id="address" size="40" value="<?php echo $this->user->get( 'address' );?>" class="inputbox required" maxlength="50" /> * </td>
</tr>
Code: Select all
<tr>
<td width="120">
<label for="address">
<?php echo JText::_( 'Address' ); ?>:
</label>
</td>
<td>
<input class="inputbox" type="text" id="address" name="address" value="<?php echo $this->user->get('address');?>" size="40" />
</td>
</tr>
I am using Joomla 1.5.6 and Xampp
I tried using UserMeta is works fine but it does not get aligned with feilds already there in the form previously. no documentation is available on the same.
So can anyone help me ??
-
- Joomla! Apprentice
- Posts: 17
- Joined: Sun Aug 24, 2008 4:44 pm
- Location: Grand Prairie, TX
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
Have you verified that table column is there? I had issues once with not telling it the AFTER command. example: ALTER TABLE jos_users ADD business VARCHAR (100) NOT NULL AFTER name;
See if that is it.
See if that is it.
-
- Joomla! Apprentice
- Posts: 17
- Joined: Sun Aug 24, 2008 4:44 pm
- Location: Grand Prairie, TX
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
Anyone been sucessful in doing drop downs and Check boxes? I think I got the check boxes to work but still doing testing on it. I use the check boxes to flag people that want to a mailing list or exisiting customer works but has it moments. Still working the bugs out on it.
-
- Joomla! Apprentice
- Posts: 17
- Joined: Wed Aug 19, 2009 7:29 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hi,
Yeah I tried it that way but still no effect
Yeah I tried it that way but still no effect
-
- Joomla! Apprentice
- Posts: 43
- Joined: Tue May 22, 2007 9:18 am
- Location: Ahmedabad
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
Its really good post.
Thanks
Thanks
http://www.gadhavitechnologies.com <------- Outsource your Joomla work
Hire Joomla Designer / Developer / SEO (Let me know if we can't use this)
Hire Joomla Designer / Developer / SEO (Let me know if we can't use this)
-
- Joomla! Fledgling
- Posts: 4
- Joined: Wed Oct 21, 2009 11:02 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Thank you for all the comments on this forum.. it just made my day....
Just in case someone got confused with the multiple posts.. here is the entire steps organized:
To add a combo box or any other field to the default registration from :
1- Go to the database and add the new field to the Jos_users table (set it to null as other records might not have values)
2- In the libraries\joomla\database\table\user.php after the :
var $params = null; line
add your field(s) for example:
var $phone = null;
var $country = null;
3- In the components\com_user\views\register\tmpl\default.php :
(a) Add the combo validation on top under the password validation function the entire script should be:
<script type="text/javascript">
<!--
Window.onDomReady(function(){
document.formvalidator.setHandler('passverify', function (value) { return ($('password').value == value); } );
document.formvalidator.setHandler('comboverify', function (value) {
if (value==" ") { return false;
} else { return true; }
}
);
});
// -->
</script>
(b) add the additional rows based on how many fields you have added, for my example it was the phone and country... (one text field, one combo box) the html should look like this :
<tr>
<td height="40"><label id="Phonemsg" for="phone">
<?php echo JText::_( 'phone' ); ?>:</label>
</td>
<td> <input type="text" name="phone" id="phone" size="40" value="<?php echo $this->escape($this->user->get( 'phone' ));?>" class="inputbox required" maxlength="50" /><span class="error"> *</span>
</td>
</tr>
<tr>
<td height="40"> <label id="countrymsg" for="country">
<?php echo JText::_( 'Country' ); ?>:</label>
</td>
<td>
<select style="width: 270px;" id="country" name="country" class="inputbox required validate-comboverify">
<option value="" <?php if ($country == "") echo "selected=\"selected\""; ?>>-select-</option>
<?php
// added by http://www.sallyahmed.com
$countryArray = array("England","Northern Ireland","Scotland","Wales",
"United States","Germany","Ireland","Canada","Other");
foreach($countryArray as $county) {
echo "<option value=\"" . $county . "\"" .
($county == $this->user->get( 'country' ) ? ' selected="selected"' : '') .
">" . $county . "</option>";
}
?>
</select>
<span class="error"> *</span>
</td>
</tr>
NOTE: I have diverted from the post on top, the use of id and class
should be in the select tag not the option tag....
4- save and upload the files , you can see the code working on this page: http://www.prisymid.com/register.html
Similar changes can be made in:
components\com_user\views\user\tmpl\form.php adding the additional fields and including the script for the combo validation on top...
Thank you again for the great post...
Regards,
Sally Ahmed
Online Marketing - Developer
Free flash animation
Just in case someone got confused with the multiple posts.. here is the entire steps organized:
To add a combo box or any other field to the default registration from :
1- Go to the database and add the new field to the Jos_users table (set it to null as other records might not have values)
2- In the libraries\joomla\database\table\user.php after the :
var $params = null; line
add your field(s) for example:
var $phone = null;
var $country = null;
3- In the components\com_user\views\register\tmpl\default.php :
(a) Add the combo validation on top under the password validation function the entire script should be:
<script type="text/javascript">
<!--
Window.onDomReady(function(){
document.formvalidator.setHandler('passverify', function (value) { return ($('password').value == value); } );
document.formvalidator.setHandler('comboverify', function (value) {
if (value==" ") { return false;
} else { return true; }
}
);
});
// -->
</script>
(b) add the additional rows based on how many fields you have added, for my example it was the phone and country... (one text field, one combo box) the html should look like this :
<tr>
<td height="40"><label id="Phonemsg" for="phone">
<?php echo JText::_( 'phone' ); ?>:</label>
</td>
<td> <input type="text" name="phone" id="phone" size="40" value="<?php echo $this->escape($this->user->get( 'phone' ));?>" class="inputbox required" maxlength="50" /><span class="error"> *</span>
</td>
</tr>
<tr>
<td height="40"> <label id="countrymsg" for="country">
<?php echo JText::_( 'Country' ); ?>:</label>
</td>
<td>
<select style="width: 270px;" id="country" name="country" class="inputbox required validate-comboverify">
<option value="" <?php if ($country == "") echo "selected=\"selected\""; ?>>-select-</option>
<?php
// added by http://www.sallyahmed.com
$countryArray = array("England","Northern Ireland","Scotland","Wales",
"United States","Germany","Ireland","Canada","Other");
foreach($countryArray as $county) {
echo "<option value=\"" . $county . "\"" .
($county == $this->user->get( 'country' ) ? ' selected="selected"' : '') .
">" . $county . "</option>";
}
?>
</select>
<span class="error"> *</span>
</td>
</tr>
NOTE: I have diverted from the post on top, the use of id and class
should be in the select tag not the option tag....
4- save and upload the files , you can see the code working on this page: http://www.prisymid.com/register.html
Similar changes can be made in:
components\com_user\views\user\tmpl\form.php adding the additional fields and including the script for the combo validation on top...
Thank you again for the great post...
Regards,
Sally Ahmed
Online Marketing - Developer
Free flash animation
-
- Joomla! Apprentice
- Posts: 34
- Joined: Mon Nov 16, 2009 4:40 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hey... does someone know how i can add some fields that appends into one?
For example, i want the fields:
"pet name" [text box] - "type" [dropdown] - "colour" [textbox] - "eyes colour" [textbox]
And there will be at least ten clones.
And on database i want this formatting (on "pets" collumn).
pet name,type,colour,eyescolour|pet name,type,colour,eyescolour|...
So i can easily "explode" the data and print it properly
I tried to append them on both user.php and form.php but i can't figure out how to make it actuall "work".
For example, i want the fields:
"pet name" [text box] - "type" [dropdown] - "colour" [textbox] - "eyes colour" [textbox]
And there will be at least ten clones.
And on database i want this formatting (on "pets" collumn).
pet name,type,colour,eyescolour|pet name,type,colour,eyescolour|...
So i can easily "explode" the data and print it properly
I tried to append them on both user.php and form.php but i can't figure out how to make it actuall "work".
-
- Joomla! Apprentice
- Posts: 34
- Joined: Mon Nov 16, 2009 4:40 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
OMG! I fugured it out!!! hahahahahaha
The answer is: controller.php! Just get all the needed vars there and then set them as you wish!
The answer is: controller.php! Just get all the needed vars there and then set them as you wish!
-
- Joomla! Fledgling
- Posts: 1
- Joined: Tue Nov 24, 2009 6:12 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hi all....
WOW thanks a lot for the all your ideas.
i have need to get help for the following problem. any help is greatly appreciated.
i have successfully add new fields to the registration page. but i need to add my own validation rule to it. how can i overcome this problem.
Thank you..
WOW thanks a lot for the all your ideas.
i have need to get help for the following problem. any help is greatly appreciated.
i have successfully add new fields to the registration page. but i need to add my own validation rule to it. how can i overcome this problem.
Thank you..
-
- Joomla! Enthusiast
- Posts: 114
- Joined: Fri Aug 22, 2008 3:37 pm
- Location: India
- Contact:
Re: My "HOW TO" extended fields in registration. No EXT needed.
This thread has been very helpful.
While going through this thread, I have ran through some doubts.
First my requirements, since I want to trace my referrals so I created an extra field in the Joomla Registration which is somewhat like this "Referral Username/Email". Since this is a referral, so I dont want to make this mandatory.
1. I want to validate the input entered, if this is an existing email id or username of a member. How to use the Input class validations which is used for other joomla inputs in the form.php
2. I dont want to let the users edit this once this is entered, but they can see the value in it similar to the username field. How to achieve this?
3. I want to see this from the backed, so I edited this file
\Joomla\administrator\components\com_users\views\user\tmpl\form.php
But now I want to see this field in the user manager itself without going into the individual user details. I have read from some thread that we need to edit this file,
Joomla\administrator\components\com_users\views\users\tmpl\default.php
I tried to modify the above file but I am not getting any result.
Any help in this regard is welcome.
Thanks
While going through this thread, I have ran through some doubts.
First my requirements, since I want to trace my referrals so I created an extra field in the Joomla Registration which is somewhat like this "Referral Username/Email". Since this is a referral, so I dont want to make this mandatory.
1. I want to validate the input entered, if this is an existing email id or username of a member. How to use the Input class validations which is used for other joomla inputs in the form.php
2. I dont want to let the users edit this once this is entered, but they can see the value in it similar to the username field. How to achieve this?
3. I want to see this from the backed, so I edited this file
\Joomla\administrator\components\com_users\views\user\tmpl\form.php
But now I want to see this field in the user manager itself without going into the individual user details. I have read from some thread that we need to edit this file,
Joomla\administrator\components\com_users\views\users\tmpl\default.php
I tried to modify the above file but I am not getting any result.
Any help in this regard is welcome.
Thanks
-
- Joomla! Fledgling
- Posts: 1
- Joined: Wed Oct 07, 2009 6:01 pm
Re: My "HOW TO" extended fields in registration. No EXT needed.
this thread is very helpful... thanks to all experts here... all working great
also what if i want to put datas it different table and field
example:i will not use jos_user table, instead i will use table called 'table_details' inside 'field_info' ?
i think i'll just edit or add a process script that will Insert that information to that specific location but i don't know how to do it. is this possible? pls help thanks in advance
thanks in advance
also what if i want to put datas it different table and field
example:i will not use jos_user table, instead i will use table called 'table_details' inside 'field_info' ?
i think i'll just edit or add a process script that will Insert that information to that specific location but i don't know how to do it. is this possible? pls help thanks in advance
thanks in advance
-
- Joomla! Apprentice
- Posts: 5
- Joined: Mon Apr 06, 2009 9:07 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
May i ask if there is a way to edit the detail in the "edit detail" link when user login?
<tr>
<td class="key">
<label for="school">
<?php echo JText::_( 'School' ); ?>
</label>
</td>
<td>
<input class="inputbox" type="text" name="school" id="school" size="40" value="<?php echo $this-
>user->get('school'); ?>" />
</td>
</tr>
The value did show up in the edit detail page, but i couldn't change the value as there is no textbox or anything. Please advice.
Thanks!
<tr>
<td class="key">
<label for="school">
<?php echo JText::_( 'School' ); ?>
</label>
</td>
<td>
<input class="inputbox" type="text" name="school" id="school" size="40" value="<?php echo $this-
>user->get('school'); ?>" />
</td>
</tr>
The value did show up in the edit detail page, but i couldn't change the value as there is no textbox or anything. Please advice.
Thanks!
-
- Joomla! Intern
- Posts: 65
- Joined: Thu Dec 17, 2009 11:42 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hi all just a quick question.
I have followed the instruction from the original post (1st post by jtullous) Thank very much by the way it was a great help.
I added in a new field in the registration form called county and it saves to the database which is great.
My question is what do I have to do to get the new field 'county' to show up in the User Manager Back end admin page?
Any help greatly appreciated
Ciaran
I have followed the instruction from the original post (1st post by jtullous) Thank very much by the way it was a great help.
I added in a new field in the registration form called county and it saves to the database which is great.
My question is what do I have to do to get the new field 'county' to show up in the User Manager Back end admin page?
Any help greatly appreciated
Ciaran
-
- Joomla! Fledgling
- Posts: 4
- Joined: Wed Oct 21, 2009 11:02 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hi Ciaranc, I have added the field to the user manager back end admin page by modifying this file:ciaranc wrote:Hi all just a quick question.
I have followed the instruction from the original post (1st post by jtullous) Thank very much by the way it was a great help.
I added in a new field in the registration form called county and it saves to the database which is great.
My question is what do I have to do to get the new field 'county' to show up in the User Manager Back end admin page?
Any help greatly appreciated
Ciaran
administrator/components/com_users/views/user/tmpl/form.php
You should add sth like this:
<input type="text" name="county" id="county" class="inputbox" size="40" value="<?php echo $this->user->get('county'); ?>" />
If you need the new field to show in the users listing in the admin panel change this file:
administrator/components/com_users/views/users/tmpl/default.php
Let me know if you need more instruction... contact me through my site
Cheers,
Sally
http://www.sallyahmed.com
-
- Joomla! Apprentice
- Posts: 8
- Joined: Thu Mar 04, 2010 9:46 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
Thanks for this tut...
as far as i understand...
i can add any number of fields to the registration form....
what if i wanna add some jquery or javascript validation to the form should i do as i would have done in a normal php form...
create a .js file and link that file in the php...
Or there is some other way to do that here....?
as far as i understand...
i can add any number of fields to the registration form....
what if i wanna add some jquery or javascript validation to the form should i do as i would have done in a normal php form...
create a .js file and link that file in the php...
Or there is some other way to do that here....?
-
- Joomla! Fledgling
- Posts: 2
- Joined: Thu Jan 28, 2010 12:08 pm
Re: My "HOW TO" extended fields in registration. No EXT needed.
Hello,
great thread and usefull I´m shure.
My Question, where can I find the URL for the Link (Register) in the Loginbox.
I would use my own Form, who create easy with Fabrik (fabrik.com).
The main request was, to modify less corefiles. All works fine, without change any core file. Only the link to register would change in Corefile.
Thats OK for me. But, where can I find it ?
Mayby, any hints to do it.. my target URL is clear, a form in Joomla (as a link of a MainMenu).
Thanks in advance.
great thread and usefull I´m shure.
My Question, where can I find the URL for the Link (Register) in the Loginbox.
I would use my own Form, who create easy with Fabrik (fabrik.com).
The main request was, to modify less corefiles. All works fine, without change any core file. Only the link to register would change in Corefile.
Thats OK for me. But, where can I find it ?
Mayby, any hints to do it.. my target URL is clear, a form in Joomla (as a link of a MainMenu).
Thanks in advance.
-
- Joomla! Apprentice
- Posts: 8
- Joined: Thu Apr 22, 2010 10:45 am
Re: My "HOW TO" extended fields in registration. No EXT needed.
How do I go about changing the registration informatin to add more fields.
This is standard joomla 'Create An Account'
Registration
Name: *
Username: *
E-mail: *
Password: *
Verify Password: *
Fields marked with an asterisk (*) are required.
Register
I need to add like 20 more fields...
This is standard joomla 'Create An Account'
Registration
Name: *
Username: *
E-mail: *
Password: *
Verify Password: *
Fields marked with an asterisk (*) are required.
Register
I need to add like 20 more fields...
-
- Joomla! Fledgling
- Posts: 1
- Joined: Mon Apr 26, 2010 4:07 pm
My "HOW TO" extended fields in registration. No EXT needed
Hello. Tanks a lot for your post. I modified my joomla files as you described and it work good!
I have only a problem. When I recive the confirmation email, I read only the 3 originalfields: name, User and email.
What is the file to modify?
Thanks
I have only a problem. When I recive the confirmation email, I read only the 3 originalfields: name, User and email.
What is the file to modify?
Thanks