I did an upgrade from 1.5.5.1 to 1.5.6 but now I get errors in the log of, I know it seems theme related however I wound think the variable is actually correct? Can anyone spot what may be wrong here or even better how to resolve it?
014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/latest.tpl on line 12
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/latest.tpl on line 49
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/featured.tpl on line 12
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/featured.tpl on line 49
latest.tpl
line 12 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
line 49 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
features.tpl
line 12 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
line 49 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
cheers
r4nd0m
014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/latest.tpl on line 12
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/latest.tpl on line 49
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/featured.tpl on line 12
2014-04-06 13:13:37 - PHP Notice: Undefined index: description in /home/dom.co.uk/catalog/view/theme/otp790_orange/template/module/featured.tpl on line 49
latest.tpl
line 12 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
line 49 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
features.tpl
line 12 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
line 49 <?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
cheers
r4nd0m
I have already reported this issue in the bug reports of the forum. The issue is the way the description with one or many database tables are not quoted during queries.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
cheers for clarifying this - any eta for a fix - or could I fix it temporarily myself assuming this applies to all 1.5.6* versions?straightlight wrote:I have already reported this issue in the bug reports of the forum. The issue is the way the description with one or many database tables are not quoted during queries.
A temporary fix will be posted shortly.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
upgraded to 1.5.6.2 error no longer exists ... but description isn't shown as previously ...
the call for the description is:
<?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
but only "..." is shown ... but it worked on a previous version just fine ...
the call for the description is:
<?php echo "<p>".mb_substr(strip_tags(html_entity_decode($product['description'])), 0, 90)."...</p>"; ?>
but only "..." is shown ... but it worked on a previous version just fine ...
I have the same problem, and I found the solution, is easy. find /catalog/controller/module/featured.php and add
description' => $product_info['description'],
in the data['products'][] array as I show you below
$this->data['products'][] = array(
'product_id' => $product_info['product_id'],
'thumb' => $image,
'name' => $product_info['name'],
'description' => $product_info['description'],
'price' => $price,
'special' => $special,
'rating' => $rating,
'reviews' => sprintf($this->language->get('text_reviews'), (int)$product_info['reviews']),
'href' => $this->url->link('product/product', 'product_id=' . $product_info['product_id'])
);
in my case this works in the 50% because now I see that php tag_strips it is not working in featured.tpl
<?php echo utf8_substr( strip_tags(strip_tags($product['description'])),0,85);?>
the result is next:
<p>This sleeveless top will help you stay cool and classy on those hotter days ...
I'will fix this problem as fast as I can
description' => $product_info['description'],
in the data['products'][] array as I show you below
$this->data['products'][] = array(
'product_id' => $product_info['product_id'],
'thumb' => $image,
'name' => $product_info['name'],
'description' => $product_info['description'],
'price' => $price,
'special' => $special,
'rating' => $rating,
'reviews' => sprintf($this->language->get('text_reviews'), (int)$product_info['reviews']),
'href' => $this->url->link('product/product', 'product_id=' . $product_info['product_id'])
);
in my case this works in the 50% because now I see that php tag_strips it is not working in featured.tpl
<?php echo utf8_substr( strip_tags(strip_tags($product['description'])),0,85);?>
the result is next:
<p>This sleeveless top will help you stay cool and classy on those hotter days ...
I'will fix this problem as fast as I can
I have the same problem, and I found the solution, is easy. find /catalog/controller/module/featured.php and add
description' => $product_info['description'],
in the data['products'][] array as I show you below
$this->data['products'][] = array(
'product_id' => $product_info['product_id'],
'thumb' => $image,
'name' => $product_info['name'],
'description' => $product_info['description'],
'price' => $price,
'special' => $special,
'rating' => $rating,
'reviews' => sprintf($this->language->get('text_reviews'), (int)$product_info['reviews']),
'href' => $this->url->link('product/product', 'product_id=' . $product_info['product_id'])
);
in my case this works in the 50% because now I see that php tag_strips it is not working in featured.tpl
<?php echo utf8_substr( strip_tags(strip_tags($product['description'])),0,85);?>
the result is next:
<p>This sleeveless top will help you stay cool and classy on those hotter days ...
Finally I change featured.tpl in your theme in the description location
<p><?php echo mb_substr( strip_tags(html_entity_decode($product['description'])),0,85);?>...</p>
description' => $product_info['description'],
in the data['products'][] array as I show you below
$this->data['products'][] = array(
'product_id' => $product_info['product_id'],
'thumb' => $image,
'name' => $product_info['name'],
'description' => $product_info['description'],
'price' => $price,
'special' => $special,
'rating' => $rating,
'reviews' => sprintf($this->language->get('text_reviews'), (int)$product_info['reviews']),
'href' => $this->url->link('product/product', 'product_id=' . $product_info['product_id'])
);
in my case this works in the 50% because now I see that php tag_strips it is not working in featured.tpl
<?php echo utf8_substr( strip_tags(strip_tags($product['description'])),0,85);?>
the result is next:
<p>This sleeveless top will help you stay cool and classy on those hotter days ...
Finally I change featured.tpl in your theme in the description location
<p><?php echo mb_substr( strip_tags(html_entity_decode($product['description'])),0,85);?>...</p>
Who is online
Users browsing this forum: tamajama@gmail.com and 77 guests