Claudia M Posted May 13, 2018 Share Posted May 13, 2018 In the United States we, or me, usually measure by L (length - Longest) W (width – second Longest *this could be depth also) H (height - The height of an item) In this Order When product dimensions was added in CC6.2.0 (Thank you by the way) the code didn’t really reflect the order or wording I wanted to use. Therefore I made the following changes and this happens: When I refreshed my browser it all looked good, but when I cleared cache in admin the dimensions disappeared from the store webpage and I get this error: [Exception] /home/claudias/public_html/includes/lib/smarty/sysplugins/smarty_internal_templatecompilerbase.php:181 - Syntax error in template "file:/home/claudias/public_html/admin_YYines/skins/default/templates/products.index.php" on line 181 " {Product Length} " unknown tag "Product" In admin/skins/default/templates/products.index Lines 181 -183 All I changed was the Label Name and the order <div><label for="product_depth">Length</label><span><input name="product_depth" id="product_depth" class="textbox number" type="text" value="{$PRODUCT.product_depth}"></span></div> <div><label for="product_width">Width / Depth</label><span><input name="product_width" id="product_width" class="textbox number" type="text" value="{$PRODUCT.product_width}"></span></div> <div><label for="product_height">Height</label><span><input name="product_height" id="product_height" class="textbox number" type="text" value="{$PRODUCT.product_height}"></span></div> Change skin/templates/content.product to the following: {if $PRODUCT.product_width > 0 && $PRODUCT.product_height > 0 && $PRODUCT.product_depth > 0} <tr> <td class="pp-spec-txt bold">Item Size</td> <td class="pp-spec-txt">{floatval($PRODUCT.product_depth)}{if $PRODUCT.dimension_unit=='in'}L x {floatval($PRODUCT.product_width)}{if $PRODUCT.dimension_unit=='in'}W{/if} x {floatval($PRODUCT.product_height)}{if $PRODUCT.dimension_unit=='in'}H{/if} {else} {$PRODUCT.dimension_unit}{/if}</td> </tr> <tr> <td class="pp-spec-txt-sm" colspan="2">Rounded to the nearest quarter inch</td> </tr> {/if} Link to comment Share on other sites More sharing options...
bsmither Posted May 13, 2018 Share Posted May 13, 2018 Is this still happeneing? I see nothing wrong with the template as you have edited it. Link to comment Share on other sites More sharing options...
Claudia M Posted May 13, 2018 Author Share Posted May 13, 2018 Yeah, it's still happening in the error where it says {Product Length} in a box next to it is says {$PRODUCT.product_depth} I'm thinking I might have this working. It's showing now but without some of my edits. Link to comment Share on other sites More sharing options...
bsmither Posted May 13, 2018 Share Posted May 13, 2018 Weird. On a side note, I also notice that you have added an HTML comment begin tag in the wrong place: <!-- <fieldset> <legend>{$LANG.catalogue.title_misc}</legend> <div><label for="upc_code">{$LANG.catalogue.product_upc}</label><span><input name="upc" id="upc" class="textbox" type="text" value="{$PRODUCT.upc}" maxlength="20"></span></div> Change to: <fieldset> <legend>{$LANG.catalogue.title_misc}</legend> <!-- <div><label for="upc_code">{$LANG.catalogue.product_upc}</label><span><input name="upc" id="upc" class="textbox" type="text" value="{$PRODUCT.upc}" maxlength="20"></span></div> Link to comment Share on other sites More sharing options...
Claudia M Posted May 13, 2018 Author Share Posted May 13, 2018 Ok I had created my own database field "Item Size" and populated it for ex. 10L x 4W x 8H but I wanted to change this to use the new product dimensions in CC in cause a shipping module ends up using them in the future. When I edit an item and clear the cache (gold box) new code does not show. Since I'm changing the database (removing MY item size) I go in to maintenance and clear ALL the caches cache, sql language and for good measure image. Look at the page I justed edited and all my styling is gone and the new dimensions do not show. So I go info my FTP and manually clear the cache - cache and skin. This brings the style back but not the new dimensions. So I go to admin and clear the cache (box not gold) and new dimensions still not there . Then I notice that the item I am editing is a brochure so there is no, for me for now, length. When I change the length to 0.100 it works. So I guess you have to show something in all dimensions for it to work. Humm.. some of my items are postcards and don't have a length. Is this going to be a problem? And why do I have tocleard the cache in so many ways not just for this but when I make skin changes? 4 minutes ago, bsmither said: Weird. On a side note, I also notice that you have added an HTML comment begin tag in the wrong place: <!-- <fieldset> <legend>{$LANG.catalogue.title_misc}</legend> <div><label for="upc_code">{$LANG.catalogue.product_upc}</label><span><input name="upc" id="upc" class="textbox" type="text" value="{$PRODUCT.upc}" maxlength="20"></span></div> Change to: <fieldset> <legend>{$LANG.catalogue.title_misc}</legend> <!-- <div><label for="upc_code">{$LANG.catalogue.product_upc}</label><span><input name="upc" id="upc" class="textbox" type="text" value="{$PRODUCT.upc}" maxlength="20"></span></div> I rearranged the file since I'm not using some of the stock code. Must have missed that. Thanks Link to comment Share on other sites More sharing options...
bsmither Posted May 13, 2018 Share Posted May 13, 2018 While you are working on skin changes, in admin, Store Settings, Advanced tab, disable caching. Sure, the store will be slower to respond, but your skin changes should be seen immediately - at least they did in earlier versions. Use 0.0001 for the thickness of the post card. Link to comment Share on other sites More sharing options...
Claudia M Posted May 13, 2018 Author Share Posted May 13, 2018 Thanks Brian, I'll do that. I fixed that file Link to comment Share on other sites More sharing options...
bsmither Posted May 14, 2018 Share Posted May 14, 2018 Just looked at the template file. I do not see the HTML comment begin tag. The comment end tag is still there. Link to comment Share on other sites More sharing options...
Claudia M Posted May 14, 2018 Author Share Posted May 14, 2018 Thanks Brian. Now I think I really have it fixed! I hope LOL Link to comment Share on other sites More sharing options...
Dirty Butter Posted July 14, 2018 Share Posted July 14, 2018 I rearranged my length, width, depth as well. We do get some international orders, so I left the Language entries for other languages as is. Somewhere along the way I got the idea that these dimensions were going to show on the storefront like 10"x6"x3", but I'm seeing a separate row for each dimension. Is the separate row the stock way in 6.2.1+? Link to comment Share on other sites More sharing options...
bsmither Posted July 14, 2018 Share Posted July 14, 2018 For CC621, I will say that each dimension will be on a separate row as per the stock Foundation code for that version. Compared to earlier versions, I am also no longer seeing the code that says if any one dimension is missing, then none get displayed. Link to comment Share on other sites More sharing options...
Dirty Butter Posted July 14, 2018 Share Posted July 14, 2018 I commented out the weight line, as I needed an easy way to require Priority Mail for all toys that make sounds. Too many are damaged in shipment via First Class. So all those have a weight of 1lb regardless of actual weight. Also, I plan to use the dimensions for packaged size - not item size. We bubble wrap any toy with hard eyes, etc, or rattles - anything that could break in shipment. So if the time ever comes that USPS requires the dimensions - all my new listings or updated listings will already have that ready to use. I'm adding as I edit/list - but have it all hidden in storefront for now. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.