Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2009
    Posts
    28
    Plugin Contributions
    0

    Default New Custom detail field needs to req'd

    Hi, I have worked my through this thread that has instructions about adding a new field to the Customer detail form

    The field I added is for the customer to provide thier website address. This is required for my process to work.

    I have hunted through the Forum and can find many examples about removing required status for exisitng customer details.

    The field is on the form, the astrick has been added, the field is in the Admin>Customer details.

    All is good except I can't see how to make this field required when the customer registers.

    I am using ZC 1.38a
    Fresh install with Blank sidebox mod

    Can some direct me to a solution:

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: New Custom detail field needs to req'd

    Look to the other required entries like first name in tpl_modules_create_account.php
    Code:
    <label class="inputLabel" for="firstname">
    <?php echo ENTRY_FIRST_NAME; ?></label>
    <?php echo zen_draw_input_field('firstname', '',
    zen_set_field_length(TABLE_CUSTOMERS, 'customers_firstname',
     '40') . ' id="firstname"') . 
    (zen_not_null(ENTRY_FIRST_NAME_TEXT) ? '<span class="alert">'
     . ENTRY_FIRST_NAME_TEXT . '</span>': ''); ?>
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Jan 2009
    Posts
    28
    Plugin Contributions
    0

    Default Re: New Custom detail field needs to be req'd

    Hi Kobra

    Thanks for the info. I have checked the file and bit for my website field looks like

    Code:
    <label class="inputLabel" for="website"><?php echo
     ENTRY_WEBSITE; ?></label>
    <?php echo zen_draw_input_field('website', $account->
    fields['customers_website'], zen_set_field_length
    (TABLE_CUSTOMERS, 'customers_website', '55'). 
    'id="website"') . (zen_not_null(ENTRY_WEBSITE_TEXT) ?
     '<span class="alert">' . ENTRY_WEBSITE_TEXT . '
    </span>': ''); ?>
    Is this right, do i understand that by having 'zen_not_null' should mean that some text needs to be entered in this field?

  4. #4
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: New Custom detail field needs to req'd

    Basically Yes, but try using the developers tool kit and searching for "ENTRY_FIRST_NAME_TEXT" to see the many files where you might need to add your custom field for full function
    Zen-Venom Get Bitten

 

 

Similar Threads

  1. Order of Invoice *by custom new field
    By sbbemn in forum Templates, Stylesheets, Page Layout
    Replies: 11
    Last Post: 8 Apr 2015, 05:07 PM
  2. Main Product detail needs space between
    By kburner in forum Templates, Stylesheets, Page Layout
    Replies: 7
    Last Post: 4 Nov 2010, 04:06 PM
  3. Custom field to the New account creation.
    By vishva8kumara in forum Managing Customers and Orders
    Replies: 2
    Last Post: 5 Oct 2009, 10:17 PM
  4. Problems adding new Product Detail field
    By swortis in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 14 May 2007, 08:06 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg