Page 1 of 1

3 dots after product description

Posted: Fri Oct 07, 2016 11:40 pm
by Renecek
Hi,
I wanted to change length of description in category page so I edited /catalog/product/category.php

FROM

Code: Select all

'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get($this->config->get('config_theme') . '_product_description_length')) . '..',
TO

Code: Select all

'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, 5000),
But I still have 3 dots after description.. Any idea please? BTW in admin section I have nothing about description length.. OC 2.2.0
Thank you

Re: 3 dots after product description

Posted: Sat Oct 08, 2016 12:31 am
by cyclops12
In admin of your shop goto extensions/themes and edit your theme.
There you will find List Description Limit...

Re: 3 dots after product description

Posted: Sat Oct 08, 2016 12:36 am
by Renecek
Ah thank you, category.php changed back to original and edited length in admin but now I have 5 dots there..

http://vino.royalweb.sk/sortiment-vin


in /catalog/controller/product/category.php have now:
$data['products'][] = array(
'product_id' => $result['product_id'],
'thumb' => $image,
'name' => $result['name'],
'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get($this->config->get('config_theme') . '_product_description_length')) . '..',
'price' => $price,
'special' => $special,
'tax' => $tax,
'minimum' => $result['minimum'] > 0 ? $result['minimum'] : 1,
'rating' => $result['rating'],
'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url)
);
}

Re: 3 dots after product description

Posted: Sat Oct 08, 2016 12:57 am
by IP_CAM
Just leave the two Quotations, but with nothing in between, if you don't like the DOT's at the end.
---

Code: Select all

'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get($this->config->get('config_theme') . '_product_description_length')) . '..',
---

Code: Select all

'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0,  50) . '',
---
Ernie
---

Re: 3 dots after product description

Posted: Sat Oct 08, 2016 1:14 am
by Renecek
I replaced it with
'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0) . '',
Description is full, it's fine but now there are 3 dots :)

Re: 3 dots after product description

Posted: Sat Oct 08, 2016 1:23 am
by IP_CAM
then, you're possibly doing this in the wrong Line ! Or you forgot, that you use some Mod, trying to achieve the same...
Ernie