Guest Terry Rogers Posted October 13, 2006 Share Posted October 13, 2006 No worrys now, I found the problem. Needed to remove <!-- BEGIN: repeat_prods --> from in between these two lines ... <div> <!-- BEGIN: repeat_prods --> <table width="100%" border="0"><tr> And also remove <!-- END: repeat_prods --> from between these two lines ... </tr></table> <!-- END: repeat_prods --> <br clear="all" /> Quote Link to comment Share on other sites More sharing options...
Guest muratuk Posted October 26, 2006 Share Posted October 26, 2006 Hi, Here's a fix for the latest products display problem. The problem is that the display is not setup to show a specific number of products across. And the <div> tags kind of go crazy and mess up the display. Here's a fix that will enable you to specify number of products to display across and will fix the line up issue. In the includes/content/index.inc.php find this line: for($i=0;$i<count($latestProducts);$i++){ Replace with this code $across=4; $index->assign("TW",100/$across); for($i=0;$i<count($latestProducts);$i++){ if (!(($i+1) % $across)) {   $index->assign("TXT_TR","</tr><tr>"); } else {   $index->assign("TXT_TR",""); } in skins/{insert skin name}/styleTemplates/content/index.tpl replace all code between <!-- BEGIN: repeat_prods --> and <!-- END: repeat_prods --> including those two lines above with this code  <table width="100%" border="0"><tr>  <!-- BEGIN: repeat_prods -->  <td width="{TW}%">   <div style="float: center; text-align: center;">   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" /></a>   <br />   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a>   <br />   {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span>   </div>  </td>  {TXT_TR}  <!-- END: repeat_prods -->  </tr></table> The $across variable is used to specify number products across. That's it. Good Luck with this code everything is ok but only you have change <tr> code to </td> then works super. original should be that. if you use <tr> your latest products displays will be mess but if you change to </td> work super. <table width="100%" border="0"></td> Quote Link to comment Share on other sites More sharing options...
Guest muratuk Posted October 26, 2006 Share Posted October 26, 2006 Hi all, Not sure if any one can help. Ive applied this fix to sort out my latest products display, but after applying it my latest products disapear... The code for index.tpl is ... <!-- BEGIN: index --> <div class="boxContent"> <span class="txtContentTitle">{HOME_TITLE}</span> <br /> {HOME_CONTENT} </div> <!-- BEGIN: latest_prods --> <div class="boxContent"> <span class="txtContentTitle">{LANG_LATEST_PRODUCTS}</span> <div> <!-- BEGIN: repeat_prods --> <table width="100%" border="0"><tr> <!-- BEGIN: repeat_prods --> <td width="{TW}%"> <div style="float: center; text-align: center;"> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" /></a> <br /> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a> <br /> {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span> </div> </td> {TXT_TR} <!-- END: repeat_prods --> </tr></table> <!-- END: repeat_prods --> <br clear="all" /> </div> <br clear="all" /> </div> <!-- END: latest_prods --> <!-- END: index --> Have I done something wrong? Website for the cart is http://www.tiffanychrister.me.uk/shop as i said i code should be <table width="100%" border="0"></td> not <table width="100%" border="0"><tr> if you put <tr> your images will be all around the page or only one line but if you replace <tr> to </td> works well. Quote Link to comment Share on other sites More sharing options...
Guest shannonlp Posted October 28, 2006 Share Posted October 28, 2006 Goober thanks for this fix it works well. I have been keeping my site W3C valid. With the orginal code it will fail validation. <!-- BEGIN: repeat_prods --> <td width="{TW}%"> <div style="float: center; text-align: center;"> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" /></a> <br /> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a> <br /> {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span> </div> </td> {TXT_TR} <!-- END: repeat_prods --> <td></td></tr></table> You must add the <td></td>. A <tr></tr> will fail validation without having the <td></td> inside of them. So basically it should look like. <tr><td></td></tr> Hope this helps anyone that is needing to figure this out. Quote Link to comment Share on other sites More sharing options...
Guest Meow Meow Posted February 13, 2007 Share Posted February 13, 2007 Goober - Thanks for the mod. It worked GREAT. B) Quote Link to comment Share on other sites More sharing options...
Guest purpledragon Posted February 21, 2007 Share Posted February 21, 2007 My latest products box disappears. I am a total newbie to all this so will probably have done something wrong and I know I still have lots of other issues to fix on the page so maybe they are causing the problem , I dont know ? Please can someone help me. I did what muratuk said about changing the <tr> to </td> after trying what goober999 said to do but it didn't help or seem to change it at all. Thanks everyone for you patience the link is here killer skin, IE6 (doesnt work on firefox yet) Quote Link to comment Share on other sites More sharing options...
Guest purpledragon Posted February 22, 2007 Share Posted February 22, 2007 Please can anyone help me :wacko: Quote Link to comment Share on other sites More sharing options...
Guest Gottcha Posted March 10, 2007 Share Posted March 10, 2007 having the same problem ... replaced the code and now no images show up. NVM ... GOT IT WORKING....THANK YOU Quote Link to comment Share on other sites More sharing options...
Guest Mikes Web Dot Org Posted March 10, 2007 Share Posted March 10, 2007 Hi, Here's a fix for the latest products display problem. The problem is that the display is not setup to show a specific number of products across. And the <div> tags kind of go crazy and mess up the display. Here's a fix that will enable you to specify number of products to display across and will fix the line up issue. In the includes/content/index.inc.php find this line: for($i=0;$i<count($latestProducts);$i++){ Replace with this code $across=4; $index->assign("TW",100/$across); for($i=0;$i<count($latestProducts);$i++){ if (!(($i+1) % $across)) {   $index->assign("TXT_TR","</tr><tr>"); } else {   $index->assign("TXT_TR",""); } in skins/{insert skin name}/styleTemplates/content/index.tpl replace all code between <!-- BEGIN: repeat_prods --> and <!-- END: repeat_prods --> including those two lines above with this code  <table width="100%" border="0"><tr>  <!-- BEGIN: repeat_prods -->  <td width="{TW}%">   <div style="float: center; text-align: center;">   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" /></a>   <br />   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a>   <br />   {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span>   </div>  </td>  {TXT_TR}  <!-- END: repeat_prods -->  </tr></table> The $across variable is used to specify number products across. That's it. Good Luck Thanks so much. it worked. My store is coming along nicely. GOD Bless! MWDO Quote Link to comment Share on other sites More sharing options...
Guest lauriex Posted March 27, 2007 Share Posted March 27, 2007 Hi, Here's a fix for the latest products display problem. The problem is that the display is not setup to show a specific number of products across. And the <div> tags kind of go crazy and mess up the display. Here's a fix that will enable you to specify number of products to display across and will fix the line up issue. In the includes/content/index.inc.php find this line: for($i=0;$i<count($latestProducts);$i++){ Replace with this code $across=4; $index->assign("TW",100/$across); for($i=0;$i<count($latestProducts);$i++){ if (!(($i+1) % $across)) {   $index->assign("TXT_TR","</tr><tr>"); } else {   $index->assign("TXT_TR",""); } in skins/{insert skin name}/styleTemplates/content/index.tpl replace all code between <!-- BEGIN: repeat_prods --> and <!-- END: repeat_prods --> including those two lines above with this code  <table width="100%" border="0"><tr>  <!-- BEGIN: repeat_prods -->  <td width="{TW}%">   <div style="float: center; text-align: center;">   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" /></a>   <br />   <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a>   <br />   {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span>   </div>  </td>  {TXT_TR}  <!-- END: repeat_prods -->  </tr></table> The $across variable is used to specify number products across. That's it. Good Luck Thanks so much. it worked. My store is coming along nicely. GOD Bless! MWDO P L E A S E H E L P !!! I have a similar problem on my Sales Items pages - all other pages are fine. On the Sales Items, text disappears, products bump to next row, etc. and the display oddities vary from pg 1 to 5. I am using CC v3.0.15 and viewing in IE6 and IE7. Quote Link to comment Share on other sites More sharing options...
Guest wirebuy Posted August 1, 2007 Share Posted August 1, 2007 I have applied the latest products display fix and it has worked perfect with one exception. All of my in the latest_products box seem to have the vertical-align option set to "center", therefore, my products look kinda messed up when the page is loaded as the products description can vary in length substancially. I have been working for hours trying to find a way in the CSS, templates, and even the PHP code where I can change the vertical-align to "top", but this option does not seem to exist anywhere, and even when I add it in what I believe would be the proper location in the CSS or template, it still does not work. Someone please help me, it is driving me nuts . Thank You -Sean Quote Link to comment Share on other sites More sharing options...
Guest eric47905 Posted August 1, 2007 Share Posted August 1, 2007 Thanks Goober for listing that quick fix out. I know it's an oldie, but I just came to the point where I needed it, did a search and BAM there it was. Worked like a charm on the first try! :errm: Quote Link to comment Share on other sites More sharing options...
Guest fridaydreamer Posted August 11, 2007 Share Posted August 11, 2007 Worked like a charm--Thanks so much! Quote Link to comment Share on other sites More sharing options...
Guest cdtronix Posted August 13, 2007 Share Posted August 13, 2007 Hi can anyone tell me how to sort the products out by price, being ascending order. Eg £1 £5 £10 etc At the moment im not sure how they are sorted, they are all over the place. see what i mean here My Webpage Quote Link to comment Share on other sites More sharing options...
Guest sy2j Posted September 11, 2007 Share Posted September 11, 2007 Thanks to all who contributed to the latest products row display fix. Problem now sorted. Good work. Quote Link to comment Share on other sites More sharing options...
Guest aliceaod Posted October 29, 2007 Share Posted October 29, 2007 Thanks to all who contributed to the latest products row display fix. Problem now sorted. Good work. OK kids, here it goes, probably beating a dead horse here but I gotta ask...I got the latest version of CubeCart, everything displays in the Latest Products just fine out of the box EXCEPT for the vertical alignment, unless a person wants the items aligned to the top, then it's perfect out of the box, no tweaking necessary. I, however, would like my "Latest Products" items to align to the bottom of the row they appear in. I have it set for 12 items which returns 4 colums and 3 rows and they appear just fine across and down. No problems with that. The rows and columns are good out of the box. I just want each item to align to the bottom of their respective places. How do I accomplish this with the latest version of CubeCart with the "KILLER" skin applied? Which of the instructions, posted since 2005, do I use? Can someone "re-cap" this post ('cos I'm totally lost now) or submit instructions for the newest stuff? Any help MUCH appreciated! UPDATE: I figured out a way to get everything to align nicely and neatly. In the content/index.tpl, where the image gets displayed for the "latest products" , I put in the attribute of height="75" in the img tag and voila, fixed. Quote Link to comment Share on other sites More sharing options...
Guest proweb Posted November 30, 2008 Share Posted November 30, 2008 Hi I have been trying to aglin my products in "the latest products" but I cannot find the line to change (i.e <div style="float: left; text-align: center; width: {VAL_WIDTH}px; height: 150px;">) this is the code I have on skins/killer/styleTemplates/content/index.tpl <!-- BEGIN: index --> <div class="boxContent"> <span class="txtContentTitle">{HOME_TITLE}</span> <br /> {HOME_CONTENT} </div> <!-- BEGIN: latest_prods --> <div class="boxContent"> <div class="txtContentTitle">{LANG_LATEST_PRODUCTS}</div> <div style="margin-top: 10px;"> <!-- BEGIN: repeat_prods --> <div class="latestProds"> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}"><img src="{VAL_IMG_SRC}" alt="{VAL_PRODUCT_NAME}" border="0" title="{VAL_PRODUCT_NAME}" /></a> <br /> <a href="index.php?act=viewProd&productId={VAL_PRODUCT_ID}" class="txtDefault">{VAL_PRODUCT_NAME}</a> <br /> {TXT_PRICE} <span class="txtSale">{TXT_SALE_PRICE}</span> </div> <!-- END: repeat_prods --> <br clear="all" /> </div> <br clear="all" /> </div> <!-- END: latest_prods --> <!-- END: index --> ----------------------------------------------------------------------------------- Can anyone help me, I have searched and searched Kind Regards, proweb :( Quote Link to comment Share on other sites More sharing options...
Robsta Posted December 2, 2008 Share Posted December 2, 2008 Look for .latestProds in one of your stylesheets :) Quote Link to comment Share on other sites More sharing options...
Guest one8edegree Posted January 21, 2009 Share Posted January 21, 2009 Easy , just edit your layout.css thanks @Robsta!! worked wonder for me Quote Link to comment Share on other sites More sharing options...
jerseyjoe Posted March 10, 2010 Share Posted March 10, 2010 What are all those little diamond-shaped symbols? In my text editor they change to "?" � �$index->assign("TXT_TR","</tr><tr>"); } else { � �$index->assign("TXT_TR",""); Quote Link to comment Share on other sites More sharing options...
bsmither Posted March 11, 2010 Share Posted March 11, 2010 In my experience, those symbols represent Firefox's inability to show the character from some unknown font or character set. I'm just guessing here, but the file may be in a UTF-8 or UTF-16 configuration and the extended character code may be beyond Firefox's ability to figure out what to draw (or 'do' if control codes) for those characters. Your editor may be having the same problem, but indicates it differently. Can your editor show you the binary/hex variant of that file? Quote Link to comment Share on other sites More sharing options...
Guest Posted July 4, 2010 Share Posted July 4, 2010 Great fix, it has resolved the issue, even though it has changed the latest products from horizontal to vertical. How can I apply this fix so that it changes it back to horizontal, but still resolving the issue where it chops off the bottom of the pitcure within Firefox only Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.