Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2009
    Posts
    169
    Plugin Contributions
    2

    help question Manual Entry/Input State field being populated with a space

    Hi,

    I'm having a hard time figuring this out.

    I have the "State - Always display as pulldown?" set to true.

    I also use a placeholder="May Not Be Left Empty" on input text fields to give the customer a clearer idea of which fields may not be left empty.

    The problem is, when the pulldown is active, and a customer chooses a country that does not have any states defined, it shows the manual input text field, but it adds a space to it. The space eliminates the placeholder text being shown, because the space counts as a character.

    I tested out a clean install, and can confirm that the space is not something with any custom code I've coded in - it seems something somewhere in the standard 1.5.4 files is adding this space when the pulldown feature is set to true. When the pulldown feature is set to untrue, the space doesn't show up.

    I'm so confused, any help please...

  2. #2
    Join Date
    Mar 2009
    Posts
    169
    Plugin Contributions
    2

    Default Re: Manual Entry/Input State field being populated with a space

    Okay...sorry..found the problem.

    in includes/modules/create_account.php around line 445 you'll find this:
    $state = ($flag_show_pulldown_states) ? ($state == '' ? ' ' : $state) : $zone_name;

    remove the   so that it looks like this:

    $state = ($flag_show_pulldown_states) ? ($state == '' ? '' : $state) : $zone_name;

    Perhaps there's a reason for the space? Any advice?

 

 

Similar Threads

  1. v154 State field requires an input when min value is 0
    By tk42one in forum General Questions
    Replies: 3
    Last Post: 27 Apr 2016, 02:26 AM
  2. Replies: 1
    Last Post: 27 May 2013, 05:40 PM
  3. State and County Taxes not populated
    By ksduster in forum Upgrading to 1.5.x
    Replies: 0
    Last Post: 14 Jan 2012, 12:41 AM
  4. How is the Costs field populated?
    By kcarl in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 12 Aug 2010, 10:31 AM
  5. State problem with new account (when making state field not required)
    By earmsby in forum Managing Customers and Orders
    Replies: 9
    Last Post: 13 May 2007, 10:04 PM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR