VirtueMart Forum

VirtueMart 2 + 3 + 4 => Product creation => Topic started by: Bronko on January 28, 2012, 00:01:17 AM

Title: Short Description too short in Product Overview
Post by: Bronko on January 28, 2012, 00:01:17 AM
Hi all,

how can i extend the length of the short description in the Product Overview of an Category? (see attachment)
The short Description is fixed to about 40 characters.

thx...

[attachment cleanup by admin]
Title: Re: Short Description too short in Product Overview
Post by: lipes on January 28, 2012, 00:17:34 AM
good question
Title: Re: Short Description too short in Product Overview
Post by: PRO on January 28, 2012, 03:58:46 AM
<?php echo shopFunctionsF::limitStringByWord($product->product_s_desc, 40, '...') ?>
                  </p>
                  <?php } ?>


^^^ notice the 40 that can be changed.

views/category/tmpl/default.php
Title: Re: Short Description too short in Product Overview
Post by: Bronko on January 28, 2012, 10:38:07 AM
Thx... that was very fast and it solved my Problem!!!

Title: Re: Short Description too short in Product Overview
Post by: lipes on April 03, 2012, 19:58:41 PM
any solution to put this code in Product Details default.php ? i try to copy this and another codes but they doesnt work ...

Right! It works!

<?php echo shopFunctionsF::limitStringByWord($this->product->product_s_desc10'...'?>
<?php ?>


tks :)
Title: Re: Short Description too short in Product Overview
Post by: PRO on April 03, 2012, 21:00:33 PM

Quote from: lipes on April 03, 2012, 19:58:41 PM
any solution to put this code in Product Details default.php ?

i try to copy this and another codes but they doesnt work ...


lipes, I know I have explained $this(pun intended) to you before

http://forum.virtuemart.net/index.php?topic=100696.0
Title: Re: Short Description too short in Product Overview
Post by: rippergr on August 03, 2012, 17:49:19 PM
Can someone give me a little help with the same problem
In fact the problem is the oposite. My short description is very long and it doesnt seem to cut it in some characters( 40)
I changed the file to 20 characters but the result is the same.
You can see the problem here
http://www.shop.trelesprosfores.gr/index.php?option=com_virtuemart&view=category&virtuemart_category_id=436

I found solution to my problem here
http://forum.virtuemart.net/index.php?topic=99892.msg346688#msg346688
Title: Re: Short Description variable
Post by: mikekiy on December 22, 2013, 17:25:01 PM
Hi All

Does anybody know a way to make the Short Description variable an override rather than a code hack?

Having to constantly edit components/com_virtuemart/views/category/tmpl/default.php on every site each time we upgrade is tiresome.

As it isn't controlled by CSS I can't figure a way to do it - can anybody help?

Many thanks

Mike
Title: Re: Short Description too short in Product Overview
Post by: jenkinhill on December 22, 2013, 17:52:23 PM
Just use the edited template file as an override, the file should be templates/[yourjoomlatemplate]/html/com_virtuemart/category/default.php

See http://docs.virtuemart.net/tutorials/33-templating-layouts.html and http://www.ostraining.com/blog/joomla/overrides

Title: Re: Short Description too short in Product Overview
Post by: mikekiy on December 26, 2013, 21:36:46 PM
Thank you for that reply.  Very helpful.

Mike