VirtueMart Forum

VirtueMart Dev/Coding Central: VM1 (old version) => Quality & Testing VirtueMart 1.1.x => Virtuemart 1.1 Development (Archiv) => Q&T Resolved => Topic started by: xmcorporation on November 22, 2008, 04:24:24 AM

Title: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: xmcorporation on November 22, 2008, 04:24:24 AM
Hello all

I've seen this reported earlier but I'm coming forward now with this problem since I've made a fresh joomla 1.5.8 install and also a fresh virtuemart 1.1.2

Since both are fresh installs therefore the "bug" of not showing thumbnails can not be caused by some bad upgrade or whatever...

Nothing was done after both fresh installs and I hope you can realy get this fixed since it's a major problem for me. I have several clients stoped because of this.

On firefox thumbnails donĀ“t show and on IE a square with a red cross appears

(http://img253.imageshack.us/img253/4703/nothumbsffgh5.th.gif) (http://img253.imageshack.us/my.php?image=nothumbsffgh5.gif)(http://img253.imageshack.us/images/thpix.gif) (http://g.imageshack.us/thpix.php) (http://img20.imageshack.us/img20/8765/nothumbsiezq7.th.gif) (http://img20.imageshack.us/my.php?image=nothumbsiezq7.gif)
Title: Re: [SOLVED] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: xmcorporation on November 22, 2008, 14:48:15 PM
SOLUTION: As someone suggested on this forum, I used the URL field (optional) for the thumbnail image and now it works, BUT I stll consider this a very annoying bug since we have to manually create and upload the thumbs for this to work  >:(
Title: Re: [SOLVED] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: Joss on November 29, 2008, 15:09:16 PM
This should NOT be marked as solved. Having to paste the URLs for all images in not a solution.

Currently we have no product images showing in either the front or backend of the site and we are losing revenue.

Also, I notice that our button images are also missing. I have reuploaded the virtumart files from my backup, but it is still not working. We are on a secure server across the whole site

Very desperate for help as this is affecting the reputation of the company.


Site is https://www.preyuk.com


Note: the SSL certificate was reinstalled a few weeks back
Title: Re: [SOLVED] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: xmcorporation on November 29, 2008, 19:45:15 PM
Quote from: Joss on November 29, 2008, 15:09:16 PM
This should NOT be marked as solved. Having to paste the URLs for all images in not a solution.
Currently we have no product images showing in either the front or backend of the site and we are losing revenue.
Also, I notice that our button images are also missing. I have reuploaded the virtumart files from my backup, but it is still not working. We are on a secure server across the whole site
Very desperate for help as this is affecting the reputation of the company.
Site is https://www.preyuk.com
Note: the SSL certificate was reinstalled a few weeks back

I agree... it is not a solution it's a workaround, at least until the programmers aknowledge this problem.

Still... I clicked your link and I can see all the product images correctly (thumbnails and full images), I assume you used the workaround.

P.S: I've changed the title of this post from SOLVED to WORKAROUND
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: Joss on November 29, 2008, 23:01:50 PM
no, sadly I thought I had solved it - but I hadn't

I rebuilt and reinstalled the site and it worked. Unfortunately, I hadn't changed the config from my test server and it was getting the images from there! When I set the site correctly it stopped working again.

Is your site on a secure server? I am wondering whether that is a problem
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: xmcorporation on November 30, 2008, 13:22:10 PM
You're right, I just checked your site again and It's not showing the thumbnails, although the full images are showing nice...

Ok, let's try to identify the problem by going step by step:

1st - Let's take product Cowshed Bullocks pocket set (https://www.preyuk.com/shop?page=shop.product_details&flypage=flypage.tpl&product_id=59&category_id=18&vmcchk=1) as case study

2nd - Open above link with Internet Explorer and note the red cross (image missing)

3rd - Open above link with FireFox and note that no thumbnail is showing, instead a text link appears

4th - Right click that text link and choose SHOW IMAGE (I got this link https://www.preyuk.com/components/com_virtuemart/show_image_in_imgtag.php?filename=resized%2FCowshed_Bullocks_48f9b99a93e4c_180x180.jpg&newxsize=180&newysize=180&fileout= )

5th - Note that a 500 INTERNAL SERVER ERROR occurs !!!!!

CONCLUSION: I'm guessing some problem with the .htaccess file on that dir, try to temporarely rename it to BAK or something and see if it works.... also set shop images dir to 777 as suggested elsewere on this forum (not worked for me because the problem was really the thumbnail not having full http path to it).

I'm not using https on my site, but when I right click my thumbnails on my FireFox and choose SHOW IMAGE a complete path with http://www.blabla.com/blablabla/../x.jpg appears so double check your product page inside Virtuemart and see if "URL: (Optional)"  right side field (thumbnail) is really beeing used.

P.S: In my case I worked on a local server apache install (xampp) before I upload the complete virtuemart product database to the web server. I used CSV Improved (http://www.csvimproved.com/) (on legacy mode).
CSV Import can do import and export to csv files. So I built the Virtuemart product database and everything was fine, so I exported a product .csv file, and imported it to the web server, result: No thumbnails!

Then I manually edited a product on the web site and choose URL: (Optional) and gave full path to the thumbnail on the web server, generated a export csv. file and downloaded to my PC, opened with SCalc (OpenOffice) and VOILA!!! The product that I've manually edited online retained the full htpp path while all the others simply had filename.jpg

So all I had to do was add the full http path to all the others (easy to do with any spreadsheet, and a lot safer than messing around with MyPHPadmin at least for me), save it, and re-import this .csv file on the web server and after that FINALLY ALL THUMBNAILS DISPLAYED CORRECT!!!

You should also try the next following procedure before trying the stated above.

100% FULLPROOF TEST to display full and thumbnail product images on web server:
1 - Create a full product image on your local computer (ex: fullimage.jpg)
2 - Create a thumbnail product image on your local computer (ex: thumnbail.jpg)
3 - Upload both images into http://www.yourwebsite.com/components/com_virtuemart/shop_image/product via FTP
4 - Open your browser and write http://www.yourwebsite.com/components/com_virtuemart/shop_image/fullimage.jpg (see if it shows on different browsers)
5 - Open your browser and write http://www.yourwebsite.com/components/com_virtuemart/shop_image/thumnbail.jpg (see if it shows on different browsers)


Until both images are not showing correctly, you should check and correct any web server settings necessary!!! Only after both images are showing ok, you can proceed to the database thumbnail full path correction procedure!

Hope all this really helps at least identifying the problem, cause my friend I know the feeling of might loosing a client for this... I' been there also  :(
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: Joss on November 30, 2008, 14:09:34 PM
Okay - solved it

This site is on a virtual using Cpanel. We could not manage to get the ftp layer working so followed the joomla instructions of setting certain directories to 0777.

However, something must have changed on the server set up and this now caused the problems

Changing the Components directory to 755 solved the problem

I will also post this on the other related thread
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: natchang on January 19, 2009, 17:46:23 PM
I'm also having this problem when I use sub folders, the workaround does work for me but here is what I get from the subfolders:

Setting thumbs to resized/subfolder, and full to product/subfolder;

I can see the full and thumb image in my backend but only the full image in the frontend with the alt text displayed for the thumbs.

This is all through CSVI where using the default folders works fine but adding a subfolder to the file location seems to break it in the frontend, tried most of the other fixes but nothing seems to work.

Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: sapomuerto on February 04, 2009, 17:15:43 PM
Thank you Joss!!!

I had the same problem, I was looking for an answer for the last weeks. Changing the componensts directory ato 755 solved the problem. Thank you so much!!!
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: AndyNZL on February 15, 2009, 23:10:48 PM
One of the things to be careful of with virtuemart 1.1.3 is that the file manager cannot create a thumbnail for a "xxx.jpeg" image. It can create one for the main image, just not any additional images added via the file manager. Simply rename them "xxx.jpg". :-)
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: ginoyoong on April 02, 2009, 08:15:23 AM
IT TOTALLY DRIVE ME CRAZY! However, thanks for the fantastic help! Joss!
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: jawatech411 on April 06, 2009, 23:01:23 PM
GoDaddy Linux Hosting
PHP 5.0
Joomla Version 1.5.10 (CLEAN INSTALL)
Virtuemart 1.1.3 (CLEAN INSTALL)
Default Category Template           
Default FLYPAGE


I am having the same problem with thumbnail images not showing however Changing the Components directory to 755 did NOT fix the problem. I tried using this workaround method of just adding the image URL to the URL field (optional)and it worked for one product but when i added a second product using the same method neither thumbnails would show. Also I would like to clarify that when I click on the product title to bring up the full item description the thumbnails show up there, The issue is rather in the catalog browse page table layouts.

See for yourself:

http://screenedimagesinc.com


Has anyone come up with a real solution for this yet?
It's kind of a big deal for thumbnails to work properly.

I have looked everywhere in this forum and found nothing that works. :-[
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: sitebuildernow on April 09, 2009, 00:24:19 AM
Quote from: AndyNZL on February 15, 2009, 23:10:48 PM
One of the things to be careful of with virtuemart 1.1.3 is that the file manager cannot create a thumbnail for a "xxx.jpeg" image. It can create one for the main image, just not any additional images added via the file manager. Simply rename them "xxx.jpg". :-)

Thank you!!! Thank You!! I am going to start a new post for this issue because it took me hours to resolve and  your post solved it - the rest of this particular thread did not address this issue.
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: hyunikel on May 23, 2009, 19:19:11 PM
hi everybody,
I have the same problem (not being able to see products thumbnails displayed on frontend) and I read the solutions you suggested but I couldn't fix my problem. Some of the solutions I couldn't understand them.

Like the following quote posted by Joss:" This site is on a virtual using Cpanel. We could not manage to get the ftp layer working so followed the joomla instructions of setting certain directories to 0777.

However, something must have changed on the server set up and this now caused the problems

Changing the Components directory to 755 solved the problem "

thank you in advance.
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: doomed on June 26, 2009, 01:51:00 AM
Quote from: hyunikel on May 23, 2009, 19:19:11 PM
hi everybody,
I have the same problem (not being able to see products thumbnails displayed on frontend) and I read the solutions you suggested but I couldn't fix my problem. Some of the solutions I couldn't understand them.


hyunikel, according to Joss, you would need to change the attributes of the Components folder to 777.
Thats done with the chmod command, see if your FTP program does that (it probably does).
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: doomed on June 26, 2009, 02:09:31 AM
Quote from: Joss on November 30, 2008, 14:09:34 PM
Okay - solved it

This site is on a virtual using Cpanel. We could not manage to get the ftp layer working so followed the joomla instructions of setting certain directories to 0777.

However, something must have changed on the server set up and this now caused the problems

Changing the Components directory to 755 solved the problem

I will also post this on the other related thread

I have changed my Components directory all files/folders inside to 755.

I still have the problem with thumbnails. If i "copy image url" i can see something like:

http://mydomain.net/website/components/com_virtuemart/show_image_in_imgtag.php?filename=resized%2FACCESS_POINT_CLI_4a17b204633c4_90x90.jpg&newxsize=90&newysize=90&fileout=

The above url shows no image at all, its like the server is not processing it or something.


Opening the large versions works ok.
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: Blix on June 26, 2009, 09:52:55 AM
I've the solution...

just go to configuration and tick Enable Dynamic Thumbnail Resizing?

did work for me
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: blans on October 29, 2009, 14:47:13 PM
We have the same trouble. All the images for products that I uploaded with CSV come  out fine but the images for products that I uploaded with VM don't.

In our case VM puts both the normal and the thumbnail image in the same /products folder instead of putting the thumbnail in the products/resized folder.

Switching to dynamic thumbnails indeed solved the problem but it's still strange because we want to use our own thumbnails not the dynamic generated ones.



Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: compuhouse on November 20, 2009, 04:27:39 AM
Hi There,

i had the same problem as well... the thumbnails are not showing at all in the browse page but i can see them in the admin page. changing dir permissions didn't help, and ticking unticking the dynamic thumbnail didn't help aswell (when ticking the option the product pictures disappeared from the admin page) i started digging inside the files.

since the shop.browse page is using show_image_in_imgtag.php to display the thumbs i've downloaded the file and opened it with dreamweaver.

the file had the following:

<?php

/**

*

* @


Thats it... nothing else... (why?? i don't know but something happened and the code in this files is disappeared .. hack?? probably.. server security ..hmmm maybe)

any way... i reuploaded the original file and VOILA! it worked.

the original file for virtuemart 1.1.2

<?php
/**
* Image Resizer & img Tag "Filler"
*
* @author Andreas Martens <heyn@plautdietsch.de>
* @author Patrick Teague <webdude@veslach.com>
*
* @version $Id: show_image_in_imgtag.php 1279 2008-02-29 09:01:49Z soeren_nb $
* @package VirtueMart
* @subpackage core
* @copyright Copyright (C) 2004-2007 soeren - All rights reserved.
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
* VirtueMart is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See /administrator/components/com_virtuemart/COPYRIGHT.php for copyright notices and details.
*
* http://virtuemart.net
*/
define('_VALID_MOS'1);

// Get the Joomla! configuration file
$config_file '../../configuration.php';
include_once( 
$config_file );

if( !isset( 
$mosConfig_absolute_path ) ) {
// We are in J! 1.5
define'_JEXEC');
$mosConfig_absolute_path dirname$config_file );
}

include_once(
"../../administrator/components/com_virtuemart/virtuemart.cfg.php");

// Image2Thumbnail - Klasse einbinden 
include( CLASSPATH "ps_main.php");
include( 
CLASSPATH "class.img2thumb.php");

$basefilename = @basename(urldecode($_REQUEST['filename']));
$filenames[] = IMAGEPATH."product/".$basefilename;
$resized_filenames[] = IMAGEPATH."product/resized/".$basefilename;
$filenames[] = IMAGEPATH."category/".$basefilename;
$resized_filenames[] = IMAGEPATH."category/resized/".$basefilename;
$newxsize = (int)@$_REQUEST['newxsize'] == PSHOP_IMG_WIDTH : (int)@$_REQUEST['newxsize'];
$newysize = (int)@$_REQUEST['newysize'] == PSHOP_IMG_WIDTH : (int)@$_REQUEST['newysize'];
// Don't allow sizes beyond 2000 pixels
$newxsize min$newxsize2000 );
$newysize min$newysize2000 );

$maxsize false;
$bgred 255;
$bggreen 255;
$bgblue 255;

/*
if( !isset($fileout) )
$fileout="";
if( !isset($maxsize) )
$maxsize=0;
*/

/* Minimum security */
$file_exists false;
$i 0;
foreach ( 
$filenames as $file ) {
if( file_exists$file ) ) {
$file_exists true;
$filename $file;
break;
} elseif( file_exists($resized_filenames[$i])) {
$file_exists true;
$filename $resized_filenames[$i];
break;
}
++$i;
}
$file_exists or die('File does not exist');

$filename2 $resized_filenames[$i];

$fileinfo pathinfo$filename );
$file str_replace(".".$fileinfo['extension'], ""$fileinfo['basename']);
// In class.img2thumb in the function NewImgShow() the extension .jpg will be added to .gif if imagegif does not exist.

// If the image is a gif, and imagegif() returns false then make the extension ".gif.jpg"

if( $fileinfo['extension'] == "gif") {
  if( 
function_exists("imagegif") ) {
    
$ext ".".$fileinfo['extension'];
    
$noimgif="";
  }
  else {
    
$ext ".jpg";
    
$noimgif ".".$fileinfo['extension'];
  }

else {
  
$ext =  ".".$fileinfo['extension'];
  
$noimgif="";
}

if( 
file_exists($filename2)) { 
$fileout $filename2;
} else {
$fileout dirname$filename2 ) .'/'.$file."_".$newxsize."x".$newysize.$noimgif.$ext;
}

// Tell the user agent to cache this script/stylesheet for an hour
$age 3600;
header'Expires: '.gmdate'D, d M Y H:i:s'time()+ $age ) . ' GMT' );
header'Cache-Control: max-age='.$age.', must-revalidate' );

if( 
file_exists$fileout ) ) {
  
/* We already have a resized image
  * So send the file to the browser */

  
switch(strtolower($ext))
{
case ".gif":
header ("Content-type: image/gif");
readfile($fileout);
break;
case ".jpg":
header ("Content-type: image/jpeg");
readfile($fileout);
break;
case ".png":
header ("Content-type: image/png");
readfile($fileout);
break;
}
}
else {
 
/* We need to resize the image and Save the new one (all done in the constructor) */
  
$neu = new Img2Thumb($filename,$newxsize,$newysize,$fileout,$maxsize,$bgred,$bggreen,$bgblue);
  

  
/* Send the file to the browser */
  
switch($ext)
{
case ".gif":
header ("Content-type: image/gif");
readfile($fileout);
break;
case ".jpg":
header ("Content-type: image/jpeg");
readfile($fileout);
break;
case ".png":
header ("Content-type: image/png");
readfile($fileout);
break;
}
}
?>


If you have the same problem maybe this is not the solution for you but if you check show_image_in_imgtag.php located in Components/Virtuemart the problem/solution has to be there.

Good luck all.... [SOLVED for me]
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: mallepiet on November 21, 2009, 23:30:52 PM
Help! Please!

After two nights of desperate trying, to get my Virtuemart images back. I need help!
Someone with a wise solution? Please try.


I have transferred a completely good working Joomla, from a test database to the final other database (different host), with Joompack backup.

Unpacked on final server,
Changed .htacces,
Configuration.php,
Relative path for Joomla tmp and log
Url's for Virtuemart

So all seems fine, site runs ok, all links work all good..... but no small image in productscroller?  :o

Ive Checked the path from VM  shop_image, .... All good.

Very strange . All pictures are there in VM backend.......no small pic in productscroller backend,  but when I click on where the pic should be. It opens perfect (big pic).

So all pictures seems fine and on the server!!!!!!!!!!!!!    ???   ???   ???



Now here is the trick.... When I changed the Theme in VM Config panel from "product list (no table, divbased)" to  "Flat product list 1 product per row" ....... The small pics appear!!!   :P

Now im thinking template.... Maybe wrong dimension somewhere? But even stranger this layout works for me on the test server!!!!

So the only thing I could think of  is ... chmod... and try to put all filles on 755 with ws-ftpro.
(don't know the best way to do so)

But still nothing......no pics.

2 days work now, probebly one little tik somewhere.


Please think with me ! and give me a next option. On the other server it works.. what did I forgot???

Thanks Pietje.

Pic: 



[attachment cleanup by admin]
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: Uriel on March 24, 2010, 14:38:17 PM
None of these options work for me....
Any other ideas ?

Thing is my site was working perfectly well showing thumbnails. It got hacked and restored and now its not working.

Something I just noticed :
/www/components/com_virtuemart/shop_image/product /resized
does not exist on the Server ? is this possibly why we having these issues?

www.scrapbooking-scrapbook.co.za
Joomla 1.0
VM 1.1.2
Title: Re: [WORKAROUND] Thumbnails not showing virtuemart 1.1.2 with joomla 1.5.8
Post by: sanala on September 28, 2011, 05:34:11 AM
Hi,
I had the same issue.
Changing the CHMOD on the component back to 755 fixed it.
Thank you all.