Hi,
Can someone put me in the right direction here, as my main images are not showing in
zen-cart-v1.5.1-full-fileset-09182012
I was using
Image Handler 4 for v1.5.x - Version: v4.3.1, but it did not show the images in the IH manager in admin (see post above - and included screen shots), so I did a complete uninstall of IH4.3.1 (used the IH built in uninstaller from ZC_admin), and deleted all the files that IH left behind (checked against the original IH file structure), also deleted the bmz_cache folder.
As it is suggested in your
image_handler_readme.html, zen_lightbox needs to be installed (or some files to be re-written) after IH installation.
Therefore I uninstalled
zen_lightbox-v1.6.4_1, by manually deleting all the files and running the uninstall.sql to make sure that nothing remainde of both IH and zen_lightbox installations.
Following your install instructions, I did reinstall
Image Handler 4 for v1.5.x - Version: v4.3.2. In ZC_admin the installation went ok (all green messages).
Then I proceeded with the installation of
zen_lightbox-v1.6.4_1
Here is the URL of a test product:
http://leather-jackets-leather-fashi...t-002-p-9.html
Looking at the DOM source of the page, I am puzzled by looking at the directories that the images are located in:
- productMainImage: <img src="images/medium/FOLDER_NAME/002_MED.jpg".........../>
- productAdditionalImages: <img src="images/FOLDER_NAME/002_01.jpg"........./>
Here is part of the DOM source code:
Code:
<!--bof Main Product Image -->
<div id="productMainImage" class="centeredContent back">
<script language="javascript" type="text/javascript">
<!--
document.write('<a href="bmz_cache/3/350e73bc2a07baf3477b70c4fa4a3c69.image.736x800.jpg" rel="lightbox-g" title="High-Neck Leather Jacket - 002"><img src="images/medium/FOLDER_NAME/002_MED.jpg" alt="High-Neck Leather Jacket - 002" title=" High-Neck Leather Jacket - 002 " /><br /><span class="imgLink">larger image</span></a>');
//-->
</script>
<a href="bmz_cache/3/350e73bc2a07baf3477b70c4fa4a3c69.image.736x800.jpg" rel="lightbox-g" title="High-Neck Leather Jacket - 002"><img src="images/medium/FOLDER_NAME/002_MED.jpg" alt="High-Neck Leather Jacket - 002" title=" High-Neck Leather Jacket - 002 "><br><span class="imgLink">larger image</span></a>
<noscript>
<a href="http://leather-jackets-leather-fashion.com/index.php?main_page=popup_image&pID=9" target="_blank"><img src="images/medium/FOLDER_NAME/002_MED.jpg" alt="High-Neck Leather Jacket - 002" title=" High-Neck Leather Jacket - 002 " /><br /><span class="imgLink">larger image</span></a>
</noscript>
</div><!--eof Main Product Image-->
<!--bof Additional Product Images -->
<div id="productAdditionalImages">
<div class="additionalImages centeredContent back" style="width:25%;">
<script language="javascript" type="text/javascript">
<!--
document.write('<a href="bmz_cache/4/49744121e52c7d8d3fcdd0ac7c72cf72.image.661x800.jpg" rel="lightbox-g" title="High-Neck Leather Jacket - 002"><img src="images/FOLDER_NAME/002_01.jpg" alt="High-Neck Leather Jacket - 002" title=" High-Neck Leather Jacket - 002 " width="144.666666667" height="175" /><br />larger image</a>');
Here is the code from main_product_image.php, showing that IH made the needed changes:
Code:
<?php
/**mod Image Handler 4.3.2
* main_product_image module
*
* @package templateSystem
* @copyright Copyright 2005-2006 Tim Kroeger
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: main_product_image.php 4663 2006-10-02 04:08:32Z drbyte $
* Last modified by DerManoMann 2010-05-31 23:41:53
*/
if (!defined('IS_ADMIN_FLAG')) {
die('Illegal Access');
}
$products_image_extension = substr($products_image, strrpos($products_image, '.'));
//Begin Image Handler changes 1 of 2
//the next three lines are commented out for Image Handler 4
//$products_image_base = str_replace($products_image_extension, '', $products_image);
//$products_image_medium = $products_image_base . IMAGE_SUFFIX_MEDIUM . $products_image_extension;
//$products_image_large = $products_image_base . IMAGE_SUFFIX_LARGE . $products_image_extension;
$products_image_base = preg_replace('/'.$products_image_extension . '$/', '', $products_image);
$products_image_medium = DIR_WS_IMAGES . 'medium/' . $products_image_base . IMAGE_SUFFIX_MEDIUM . $products_image_extension;
$products_image_large = DIR_WS_IMAGES . 'large/' . $products_image_base . IMAGE_SUFFIX_LARGE . $products_image_extension;
//End Image Handler changes 1 of 2
//Begin Image Handler changes 2 of 2 (this entire section is commented out for Image Handler 4)
// check for a medium image else use small
//if (!file_exists(DIR_WS_IMAGES . 'medium/' . $products_image_medium)) {
// $products_image_medium = DIR_WS_IMAGES . $products_image;
//} else {
// $products_image_medium = DIR_WS_IMAGES . 'medium/' . $products_image_medium;
//}
// check for a large image else use medium else use small
//if (!file_exists(DIR_WS_IMAGES . 'large/' . $products_image_large)) {
// if (!file_exists(DIR_WS_IMAGES . 'medium/' . $products_image_medium)) {
// $products_image_large = DIR_WS_IMAGES . $products_image;
// } else {
// $products_image_large = DIR_WS_IMAGES . 'medium/' . $products_image_medium;
// }
//} else {
// $products_image_large = DIR_WS_IMAGES . 'large/' . $products_image_large;
//}
//End Image Handler changes 2 of 2 (this entire section is commented out for Image Handler 4)
/*
echo
'Base ' . $products_image_base . ' - ' . $products_image_extension . '<br>' .
'Medium ' . $products_image_medium . '<br><br>' .
'Large ' . $products_image_large . '<br><br>';
*/
// to be built into a single variable string
So please can you tell me what went wrong, and why I have 2 different URL's showing?
Many thanks for your help,
Goshawk