Totally Zenned
- Join Date:
- Jan 2007
- Location:
- Los Angeles, California, United States
- Posts:
- 10,011
- Plugin Contributions:
- 3
[Done v1.6.0] "Write Reviews" - Minor issue with model number display
Not sure if this is the right place to post this, but I wanted to share a very minor issue I discovered.. I noticed that for clients that I installed the Zen Lightbox and Colorbox add-ons that there was some weird/invalid HTML on the "read reviews" pages. The model number displays in what appears to be some weird link to the left of the product image. You can see what I mean here: http://www.zen-cart.com/attachment.php?attachmentid=12967&d=1377422852. The "write reviews" page displays correctly.
I came up with a number of bandaid solutions that work on the "read reviews" page, but then after doing some more testing and digging around, I realized that the includes/modules/pages/product_reviews/header_php.php file uses different code to display the product name and model number than the includes/modules/pages/product_reviews_write/header_php.php file. It would appear that the activation of the Zen Lightbox or Zen Colorbox add-ons simply made it easier to spot this difference.
I have tested the following fix:
in the includes/modules/pages/product_reviews/header_php.php file replace this:
if (zen_not_null($review->fields['products_model'])) {
$products_name = $review->fields['products_name'] . '<br /><span class="smallText">[' . $review->fields['products_model'] . ']</span>';
} else {
$products_name = $review->fields['products_name'];
}
with this:
$products_name = $review->fields['products_name'];
if ($review->fields['products_model'] != '') {
$products_model = '<br /><span class="smallText">[' . $review->fields['products_model'] . ']</span>';
} else {
$products_model = '';
}
It appears to solve the issue. I tested this on both a test vanilla store as well as a test store with just Zen Lightbox installed..
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.