Results 1 to 9 of 9

Hybrid View

  1. #1
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Pre-filling data in text field attribute

    How can I display field data from the "CUSTOMERS" table on to the confirmation page (page after "Add to Cart" button is clicked)?

    Zen Cart 1.3.8 (fresh install)

  2. #2
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Re: How to Add Fields for Product Personalization?

    Quote Originally Posted by Genevieve View Post
    I am building a site for products that will be personalized with customer-specified information, so I need to add a handful of custom fields to my product details page that will allow customers to enter the info they want used in the personalization of their item. Ideally, they would add this data ON the product listing page, the custom data would be held temporarily when they click "Add to cart" and then stored and displayed in their order invoice once they check out and the transaction is complete. How would I go about doing this?
    Hi, I have the similar situation. But would like to extract data from the CUSTOMERS table and transfer it on to some of the attribute text fields automatically within the product details page. Can someone please let me know how this can be done?

  3. #3
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Re: How to Add Fields for Product Personalization?

    Quote Originally Posted by qwerpoiu338 View Post
    Hi, I have the similar situation. But would like to extract data from the CUSTOMERS table and transfer it on to some of the attribute text fields automatically within the product details page. Can someone please let me know how this can be done?
    Anyone got any suggestions? Thanks in advance.

  4. #4
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Pre-filling data in text field attribute

    Created a text input field as one of the product attributes used for personalizing an item. How can I pre-fill these fields with data from $_SESSION['customer_first_name'], $_SESSION['customer_last_name'], etc.? Looked into tpl_product_info_display, tpl_modules_attributes.php and attributes.php but not sure how to do it as I'm limited with PHP codings. Any help is appreciated.

  5. #5
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Re: Options, Options, Options..

    I created a few text input fields as product attributes used for personalizing an item. Is there a way to pre-fill these fields with data from fields in CUSTOMERS table(eg. first and last name)? Looked into tpl_product_info_display, tpl_modules_attributes.php and attributes.php but not sure how to do it as I'm limited with PHP codings. I've seen something similar (pre-filling first/last name, tel num) was done on the CONTACT US page. However I really cant' figure out which files to modify for the attributes. Any help is appreciated.

  6. #6
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Options, Options, Options..

    /includes/modules/your_template/attributes.php would be the place to insert the text prefilling functionality. The text option code is built starting at line 388, and added to the output accumulator arrays at line 509.

  7. #7
    Join Date
    Dec 2007
    Location
    Ontario, Canada
    Posts
    27
    Plugin Contributions
    0

    Default Re: Pre-filling data in text field attribute

    got it to work finally. Thanks!!

  8. #8
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Pre-filling data in text field attribute

    That's good to know! Would you mind sharing how you did it? It would be a big help to others wanting the same thing.

  9. #9
    Join Date
    Feb 2010
    Posts
    45
    Plugin Contributions
    0

    Default Re: Pre-filling data in text field attribute

    Just wondering if the solution was ever posted anywhere? I have exactly the same requirement, to copy customer data and pre-populate some product attributes.

 

 

Similar Threads

  1. v151 Comparing a text attribute with a database data
    By AlexThibo in forum Managing Customers and Orders
    Replies: 0
    Last Post: 1 Nov 2013, 04:06 AM
  2. Can I have text showing inside an attribute text field
    By jcrewe in forum Setting Up Categories, Products, Attributes
    Replies: 0
    Last Post: 4 Jan 2012, 10:48 PM
  3. Adding Text Field Attribute
    By LinusIT in forum Setting Up Categories, Products, Attributes
    Replies: 5
    Last Post: 27 Jan 2011, 03:04 PM
  4. Charge for Filling in Text Box?
    By vetofunk in forum Setting Up Categories, Products, Attributes
    Replies: 4
    Last Post: 5 Jan 2008, 05:27 AM
  5. Pre fill text attribute
    By Phil020782 in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 30 Jul 2007, 10:37 AM

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