Zen Cart Logo
Forums / All Other Contributions/Addons / Extra Fields for Customer Sign Up (Create Account) Page

Extra Fields for Customer Sign Up (Create Account) Page

Views: 264,927

Results 41 to 60 of 198
23 May 2011, 8:06 PM
#41
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Extra Fields for Customer Sign Up (Create Account) Page

Hey Samfire,

Yes, give this a try in your CSS files:

input {
length: 150px;
}

It should be called stylesheet.css, or something along those lines, depending how your template is setup.

24 May 2011, 10:09 AM
#42
samfire avatar

samfire

New Zenner

Join Date:
May 2011
Posts:
2
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

jackie.taferner:

Hey Samfire,

Yes, give this a try in your CSS files:

input {
length: 150px;
}

It should be called stylesheet.css, or something along those lines, depending how your template is setup.

Thanks Jackie, I'll give that a try but wont that just change the form style generically for all customer registration text box fields as opposed to just changing the one text box field for 'extra field'?

:)

24 May 2011, 3:17 PM
#43
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

Yes, that is true. If you do not want your field lengths to match, you might try this instead.

#extrafield {
width: 150px;
}

You might find the FireBug tool for Firefox or Chrome useful in these situations. Simply right-click the form field you want to change, and click Inspect Element. You will be able to review the code and find out class or ID of the object you're trying to style.

25 May 2011, 6:45 AM
#44
soniccc avatar

soniccc

Zen Follower

Join Date:
May 2010
Location:
Cyberspace
Posts:
387
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

Is there a way to include the information from the Extra Field in the order confirmation e-mail?

Thanks

27 May 2011, 2:17 AM
#45
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

Hello, this add-on is a lifesaver and I greatly appreciate it. Thank you!

I'm looking to add multiple extra fields to the account creation and account edit pages. I've used the plugin and have been able to get everything working correctly during account creation. The problem is that when attempting to update an account, only the first extrafield that I added is being updated in the database.

Heres what I have done so far:

  1. I've added the db fields for extrafield, extrafield2, and extrafield3
  2. I've updated all of the files that came with the add-on to reflect all three extrafields is each place that the original extrafield was added. (I've double checked this)

Any suggestions?

27 May 2011, 2:48 PM
#46
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

@soniccc
haven't tried it, but in theory this should work. find this file: /includes/classes/order.php
and using 'firstname' as an example field, search through the document and every instance of 'firstname', copy and paste that line, then add your variable.

@jahmar
Sounds like there may be something missing in /includes/modules/pages/account_edit/header_php.php
Do a search for 'extrafield' and make sure there is an instance for extrafield2 and extrafield3 in every single place that the other one is.

27 May 2011, 10:11 PM
#47
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

I've checked through the file a number of times. The fields that I added are extrafield2 and extrafield3. Here is the info I have added in the various locations:

// start extrafield
$extrafield = zen_db_prepare_input($_POST['extrafield']);
$extrafield2 = zen_db_prepare_input($_POST['extrafield2']);
$extrafield3 = zen_db_prepare_input($_POST['extrafield3']);
// end extrafield

						// start extrafield
						array('fieldName'=>'customers_extrafield', 'value'=>$extrafield, 'type'=>'string'),
						array('fieldName'=>'customers_extrafield2', 'value'=>$extrafield2, 'type'=>'string'),
						array('fieldName'=>'customers_extrafield3', 'value'=>$extrafield3, 'type'=>'string'),
						// end extrafield

$account_query = "SELECT customers_gender, customers_firstname, customers_lastname,
customers_dob, customers_email_address, customers_telephone,
customers_fax, customers_extrafield, customers_extrafield2,
customers_extrafield3, customers_email_format, customers_referral

              FROM   " . TABLE_CUSTOMERS . "

Like I mentioned the infromation is correctly inserted into the database from the account creation page. Also the first extrafield updates fine from the account edit page.

Any other thoughts on what could be causing this?

27 May 2011, 10:14 PM
#48
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

Hmmm... when you go to the account edit page, are extra fields 2 & 3 blank, or are they pre-populated with the correct data from account creation?

27 May 2011, 10:22 PM
#49
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

They are pre-populated with the correct data from the account creation.

27 May 2011, 10:27 PM
#50
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

how about on the customers edit page in the admin area? can you see the field data there and edit it?

27 May 2011, 10:28 PM
#51
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

I've also tried to insert the other two values into the database directly using the following command.

$sql = "insert into " . TABLE_CUSTOMERS . " (extrafield2, extrafield3) values (:value1:, :value2:) where customers_id = :customersID";
$sql = $db->bindVars($sql, ':value1:', $extrafield2, 'string');
$sql = $db->bindVars($sql, ':value2:', $extrafield3, 'string');
$result = $db->Execute($sql);

I'm starting to think that the values are not being posted with the form submission. I've checked the field name and ids and they all match correctly.

27 May 2011, 10:32 PM
#52
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

Only my first extrafield shows up in the customer edit page of the admin area. I can add the other two extrafield to the admin files as well.

27 May 2011, 10:33 PM
#53
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

try doing that, and see if you can get the backend updates working. Let me know what happens!

27 May 2011, 10:44 PM
#54
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

It's now updating all three fields correctly from the customer edit page. Still no luck on the account edit page.

30 May 2011, 1:45 PM
#55
jahmar avatar

jahmar

New Zenner

Join Date:
Jul 2010
Posts:
9
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

I got it working. I honestly do not know how but I thank God. I prayed and placed back online my original header_php.php file and it updated the fields as expected. Thanks for your help and this great module JT.

30 May 2011, 3:20 PM
#56
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

Glad it's working for you! Sometimes strange things happen and re-uploading is what it takes.

31 May 2011, 6:16 AM
#57
soniccc avatar

soniccc

Zen Follower

Join Date:
May 2010
Location:
Cyberspace
Posts:
387
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

jackie.taferner:

@soniccc
haven't tried it, but in theory this should work. find this file: /includes/classes/order.php
and using 'firstname' as an example field, search through the document and every instance of 'firstname', copy and paste that line, then add your variable.

@jahmar
Sounds like there may be something missing in /includes/modules/pages/account_edit/header_php.php
Do a search for 'extrafield' and make sure there is an instance for extrafield2 and extrafield3 in every single place that the other one is.

Ok. I'll try that. Thanks!

26 Jun 2011, 5:52 PM
#58
ntestinfo11 avatar

ntestinfo11

New Zenner

Join Date:
Mar 2011
Posts:
39
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

Can we add more than one extra fields using this mod?

I want to add 4 fields to registration form. Does this mod work for me?

11 Jul 2011, 8:43 AM
#59
nakashima avatar

nakashima

New Zenner

Join Date:
Jul 2011
Posts:
3
Plugin Contributions:
0

Re: Extra Fields for Customer Sign Up (Create Account) Page

Thank you for this awesome plugin, it works perfectly! :D

Is it possible to make the field a dropdown with options, say for different sizes?

I tried the idea of using existing code but the only code I found was for the countries, which seems to get the information from somewhere else rather than manually entering the countries.

Thanks!

11 Jul 2011, 4:17 PM
#60
jackie_taferner avatar

jackie_taferner

Totally Zenned

Join Date:
Jun 2009
Location:
Orange County, California
Posts:
547
Plugin Contributions:
3

Re: Extra Fields for Customer Sign Up (Create Account) Page

@ntestinfo11, yes you can add more fields by following the instructions in readme.txt file

@nakashima, I am unsure why you might want sizes on the sign-up page. Perhaps you are using the sign up in a different way than intended, and there could be a better solution for your needs. Let me know what you're trying to accomplish.