Page 6 of 28 FirstFirst ... 4567816 ... LastLast
Results 51 to 60 of 272
  1. #51
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    163
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    ok, but doesn't using attributes on the user side? Meaning, when a user is say looking a tshirt, and they wantr to order it and they select their size. Isn't tht how the attributes work? That NOT what I need. Since the clothes being sold are always just one set size by the admin.

    Shopping by size doesn't have to be part of the category menu I guess, I could just make it a pull down menu or other type just below the category menu in a sidebox.

  2. #52
    Join Date
    Jan 2004
    Posts
    66,419
    Blog Entries
    7
    Plugin Contributions
    277

    Default Re: How-To: Add new Properties to your Products

    Quote Originally Posted by magneteye View Post
    ok, but doesn't using attributes on the user side? Meaning, when a user is say looking a tshirt, and they wantr to order it and they select their size. Isn't tht how the attributes work? That NOT what I need. Since the clothes being sold are always just one set size by the admin.
    Fair enough. Then attributes won't be your solution. My other comments still apply.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

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

    Default Re: How-To: Add new Properties to your Products

    Just for the record, re: post 19 (product details list and not getting your new field to display by itself), before the output <ul> section there is an if() test which only displays the list if one of its elements has a value or is set to display.

    Add your field to that test and it will trigger the list to show.

  4. #54
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Has anyone been able to add additional product fields using a separate table? Can you provide an easy 'how-to' for us with little knowledge such as the one shown here?

    Not sure if this has been posted on the wish-list, but this, along with the ability to add additional customer info fields, is essential to any growing business and probalby should be a standard feature of ZenCart.

  5. #55
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    163
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Quote Originally Posted by crazy_chris View Post
    Guarantee:

    <?php if (!empty(
    $product_info->fields['products_guarantee'])) echo $product_info->fields['products_guarantee']; ?>

    This is supposedly only going to output if something exists, but it am placing my items in a list and can't seem to figure out how to make it NOT show the list bullets (and list title) when it is empty. Can anyone help?

    EDIT:

    I figured it out on my own:

    <?php if (!empty($product_info->fields['products_guarantee'])) echo '<li>' . $product_info->fields['products_guarantee'] . '</li>'; ?>

    BUT, I can't figure out how to hide the list title if nothing exists in any of my 4 new fields that create the list.


    Here's the code as is, and obviously the "Product Features" is always there at this point:

    <p><strong>Product Features:</strong></p>

    <ul>
    <?php if (!empty($product_info->fields['products_feature1'])) echo '<li>' . $product_info->fields['products_feature1'] . '</li>'; ?>
    <?php if (!empty($product_info->fields['products_feature2'])) echo '<li>' . $product_info->fields['products_feature2'] . '</li>'; ?>
    <?php if (!empty($product_info->fields['products_feature3'])) echo '<li>' . $product_info->fields['products_feature3'] . '</li>'; ?>
    <?php if (!empty($product_info->fields['products_feature4'])) echo '<li>' . $product_info->fields['products_feature4'] . '</li>'; ?>
    </ul>
    Last edited by magneteye; 6 Nov 2007 at 08:04 PM.

  6. #56
    Join Date
    Aug 2004
    Location
    Fountain Hills, AZ
    Posts
    515
    Plugin Contributions
    1

    help question Re: How-To: Add new Properties to your Products

    Quote Originally Posted by gjh42 View Post
    Just for the record, re: post 19 (product details list and not getting your new field to display by itself), before the output <ul> section there is an if() test which only displays the list if one of its elements has a value or is set to display.

    Add your field to that test and it will trigger the list to show.
    I'm working on a product type;however it really only is adding one field to the products table for that product type. I'm having the same issue - getting the field to display on the products detail page. I've done this before, in an older version with no problems - but for some reason its giving me fits this time (I'm upgrading).
    The admin side works perfectly - all data is collected and displayed properly.

    I did as you stated above and listed the field in the test - Here is the code from that section (product_candle is the product type - burn_time is the field - )

    Code:
    <!--bof Product details list  -->
    <?php if ( (($flag_show_product_candle_info_model == 1 and $products_model != '') or <?php if ( (($flag_show_product_candle_info_burn_time == 1 and $products_burn_time != '') or ($flag_show_product_candle_info_weight == 1 and $products_weight !=0) or ($flag_show_product_candle_info_quantity == 1) or ($flag_show_product_candle_info_manufacturer == 1 and !empty($manufacturers_name))) ) { ?>
    <ul id="productDetailsList" class="floatingBox back">
      <?php echo (($flag_show_product_candle_info_model == 1 and $products_model !='') ? '<li>' . TEXT_PRODUCT_MODEL . $products_model . '</li>' : '') . "\n"; ?>
      <?php echo (($flag_show_product_candle_info_burn_time == 1 and $products_burn_time !='') ? '<li>' . TEXT_PRODUCT_BURNTIME . $products_burn_time . '</li>' : '') . "\n"; ?>
      <?php echo (($flag_show_product_candle_info_weight == 1 and $products_weight !=0) ? '<li>' . TEXT_PRODUCT_WEIGHT .  $products_weight . TEXT_PRODUCT_WEIGHT_UNIT . '</li>'  : '') . "\n"; ?>
      <?php echo (($flag_show_product_candle_info_quantity == 1) ? '<li>' . $products_quantity . TEXT_PRODUCT_QUANTITY . '</li>'  : '') . "\n"; ?>
      <?php echo (($flag_show_product_candle_info_manufacturer == 1 and !empty($manufacturers_name)) ? '<li>' . TEXT_PRODUCT_MANUFACTURER . $manufacturers_name . '</li>' : '') . "\n"; ?>
    </ul>
    Any suggestions?

  7. #57
    Join Date
    May 2007
    Posts
    136
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Hey this is a great tutorial thanks,

    I have a question, I want to use textarea instead of the input field, I looked to see how the description field was coded so I copied and replaced “zen_draw_input_field” with “zen_draw_textarea_field” and Zen Cart did not like that at all, how can I change the input field to a textarea?

    Code:
    Warning: Missing argument 4 for zen_draw_textarea_field()

  8. #58
    Join Date
    May 2007
    Posts
    136
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Ok I got it to work using the following code, I hope others find this useful
    Code:
    <?php echo zen_draw_textarea_field('products_YOUR-FIELD-NAME[' . $languages[$i]['id'] . ']', 'soft', '100%', '10', $pInfo->products_YOUR-FIELD-NAME, zen_set_field_length(TABLE_PRODUCTS, 'products_YOUR-FIELD-NAME')); ?>

  9. #59
    Join Date
    Jul 2007
    Posts
    110
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Hi,
    this issue is really bothering me as well. I will soon go insane on this!
    I also needs extra fields to choose from in admin. Some of them should be textfields, some would be dropdown with values and some would need checkboxes.

    In other carts I worked with this was not usually a problem and with Zencart that is bright and good on everything else I cant understand why this have to be such an issue.

    For my needs It would be enough to be able to create attributes in normal way but then only use them for adminpart. No customers should be able to choose anything (like magneticeyes needs)

    I really need to get this issue fixed somehow. If someone feels like they could fix this i´m willing to pay him/her to do it.

    Best regards,
    Ola

  10. #60
    Join Date
    Jul 2005
    Location
    Charlottesville, VA
    Posts
    431
    Plugin Contributions
    0

    Default Re: How-To: Add new Properties to your Products

    Quote Originally Posted by jagge View Post
    I really need to get this issue fixed somehow. If someone feels like they could fix this i´m willing to pay him/her to do it.
    There is a message board in this forum for hiring custom coding work. I've done that very successfully, worked with a developer in another country, in fact, who was familiar enough with ZC and he was able to deliver what I needed very nicely, at a fair price. What you describe is trivial for an experienced developer who knows ZC, but if you're not handy with PHP and SQL, adding extra product attribute fields is not a simple thing. It would be lovely to automate custom fields in some future edition of ZC, it would make creating custom product types a breeze, wouldn't it! The custom code will need to be nested inside several files according to the current code structure. This creates future maintenance chores for you, as you must manually merge and update files for each future ZC release. Just some things to think about.

    ---Diana

 

 
Page 6 of 28 FirstFirst ... 4567816 ... LastLast

Similar Threads

  1. change how latest products works or add new box that displays products we select
    By Sushigal in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 12 Oct 2010, 04:19 PM
  2. shopping cart contents and new properties to the products
    By stitchnkitty in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 10 Nov 2009, 05:50 PM
  3. Replies: 4
    Last Post: 20 Jun 2009, 04:06 PM
  4. !! Please help !! Add new Properties to your Products
    By JohnSquier in forum Setting Up Categories, Products, Attributes
    Replies: 4
    Last Post: 27 Feb 2008, 05:46 AM
  5. alter and add new product properties
    By jmitton in forum Setting Up Categories, Products, Attributes
    Replies: 3
    Last Post: 20 Jan 2008, 03:24 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