Short Description in Category View

GK User
Sat Nov 22, 2014 3:55 am
Hello, I am trying to insert short description in category view.
I enter the following code

<h3 class="catProductTitle"><?php echo JHTML::link($product->link, $product->product_name); ?></h3>

<div><?php echo JHTML::link($product->link, $product->product_s_desc); ?></div>

in order to show it under title, but template breaks. I have tried several methods in override.css and places in default.php, but template always breaks.
Additonnally, last product in pagination, is totally unaligned. I have set poducts in a row of 4, but last row has 3 and last product hoes down, same thing when using 5.
You can check this on https://www.growmarket.gr/bak/organikos ... -dialumata
I am using Joomla 2.5.27, VM 2.6.12.2 and last version of Storefront template.
User avatar
Fresh Boarder

teitbite
Sat Nov 22, 2014 2:37 pm
Hi

Please send me an access to ftp. I'll try to fix it.
User avatar
Moderator

GK User
Sat Nov 22, 2014 5:29 pm
teitbite wrote:Hi

Please send me an access to ftp. I'll try to fix it.

Hello , thanx for your quick response. Can you please provide me an e-mail account to send you ftp access ?
Thanx in advance,
Nikos
User avatar
Fresh Boarder

teitbite
Sun Nov 23, 2014 11:14 am
Hi

Code was fine, but looks like You have tried with a wrong file. Code should go to /html/com_virtuemart/category/default.php

It's there now and it works.
User avatar
Moderator

GK User
Sun Nov 23, 2014 8:00 pm
Hello, this was the file in which I made changes. If you go to this page, https://www.growmarket.gr/bak/organikos ... -dialumata , and proceed after 30 products, you can check how the template is broken if I add
<div><?php echo JHTML::link($product->link, $product->product_s_desc); ?></div>
in the code. You can also see that there are no margins between sidebar and mainbody.
Additionally, problem with last product in row is not solved yet.
Hope to hear from you soon ,
Nikos
User avatar
Fresh Boarder

teitbite
Mon Nov 24, 2014 2:36 pm
Hi

This means that one (or more) of the short descriptions have a validation error.

Can be fixed by using a strip_tags() function. Like this:

Code: Select all
                  <h3 class="product_s_desc"><?php echo JHTML::link($product->link, strip_tags($product->product_s_desc)); ?></h3>
User avatar
Moderator

teitbite
Mon Nov 24, 2014 2:50 pm
Hi

For the empty rows problem I need to attach a file solution. I had to remove a lot of code from this file in different places to make it work.

It's file from /html/com_virtuemart/category/default.php

TAG: VM EMPTY ROW
User avatar
Moderator


cron