VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: lostmail on March 22, 2020, 18:15:08 PM

Title: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 22, 2020, 18:15:08 PM
After update I can not upload product images.
I select an image for upload and click safe and the product image page returns but no image uploaded or visible.
the image is upladed - i can see it in the upper field where you can search for images in the image path.

Default "no image" hast now strange dimensions too in frontend and backend ?

Normally I upload a new image and click save. After that I see the resized image (thumbnail) and the big image.
this is not the case  anymore now...;-(

UPDATE:

I now have to make 2 Steps:
1.) upload the image and save
2.) search for images, select it and save the product.

Very uncomfortable now this 2-step image upload...why that ??

UPDATE 2:

I seems that only the first image has to be uploaded this 2-step way.
Additional images can be uploaded only with upload - they are than correct visible.

It seems to be a problem with the first image upload of a product.
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: jenkinhill on March 23, 2020, 10:57:11 AM
And with the last beta release,   com_virtuemart.3.6.11.10289 (http://dev.virtuemart.net/attachments/1248/com_virtuemart.3.6.11.10289_package_or_extract.zip) ?   
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 23, 2020, 11:30:22 AM
Ji Jenkinhill,

glad to see you  ;-)

Installed the update and tried upload but it still does not work with the first image...
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: jenkinhill on March 23, 2020, 11:52:11 AM
Hmm, I'm using the latest test version, VM 3.6.11 10291 and there is no issue with first product image upload.

You are the only one to report this, but there are not a large number of users testing the beta versions. I assume you have checked the console for errors and have no plugins likely to cause problems?
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 23, 2020, 19:31:07 PM
I check the "media" listing and find the not uploaded images with strange information here.

It seems there is something wrong with upload function that the first image of a product is not automatically saved and linked correct..?
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 23, 2020, 19:43:24 PM
Don`t know if it`s right but I have in Configuration/Templates => Product Media URL : images/stories/virtuemart/product/

But the wrong uploaded and not findable images  under media show the path: images/virtuemart/product/004_05-1584946800

I think it`s something going wrong here....??

Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: GJC Web Design on March 23, 2020, 23:36:06 PM
try changing Product Media URL : images/virtuemart/product/
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 24, 2020, 07:14:51 AM
no - still the same.
When a product has no image and i upload a new one there is still only the default "no image" to see.
Changed back to previous path (as it is since first installation i guess)

QuoteMessage
File /www/htdocs/w014c4cc/xxxxx/_TEST/images/stories/virtuemart/product/004_21.jpg uploaded
Product successfully saved

The image is uploaded well but it is not visible => "no image"....??

For testing I try to upload an image for a category - it`s working well... :-\

And no - there are not additional extensions in TEST System - only VM core installation without any modifications.
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 24, 2020, 08:15:32 AM
UPDATE:
It seems the file from administrator/components/com_virtuemart/models/product.php has been changed.

I uploaded the file from the official release and the upload is working well as before the update to 3.6.11.10245

This file: administrator/components/com_virtuemart/models/product.php seems to have a bug....!

Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 24, 2020, 21:21:49 PM
Another strange thing:
In the images tab of products the text for "Image Alt-Text" does not change when I add an image.

I do have to delete it manually or overwrite it...normally it should be the default file name as i remember.

Don`t know why/where this is coming from now...

As i told you I installed the BETA package 3.6.11.10245 and changed the file administrator/components/com_virtuemart/models/product.php against the file from
latest STABLE package as the image upload did not work.
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: jenkinhill on March 25, 2020, 11:05:54 AM
I thought this was intended. The product name is set for the image title and you can enter a correct alt entry yourself. It should not be the image filename, but should be a suitable description of what the image shows.  I don't like to see the default "No image set ", though.
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 25, 2020, 19:43:00 PM
Quote from: jenkinhill on March 25, 2020, 11:05:54 AM
I thought this was intended. The product name is set for the image title and you can enter a correct alt entry yourself. It should not be the image filename, but should be a suitable description of what the image shows.  I don't like to see the default "No image set ", though.

I made a language override for COM_VIRTUEMART_NO_IMAGE_SET with empty text in it - now this text is gone...
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 25, 2020, 19:50:44 PM
OK - so please rework/rapair the upload function....
Path changing in config made no change.
First uploaded image is always not visible (only "no image available).
File from STABLE works fine - BETA not.
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: jjk on March 25, 2020, 20:10:22 PM
Quote from: lostmail on March 23, 2020, 19:43:24 PM
Don`t know if it`s right but I have in Configuration/Templates => Product Media URL : images/stories/virtuemart/product/

But the wrong uploaded and not findable images  under media show the path: images/virtuemart/product/004_05-1584946800
I think it`s something going wrong here....??

I guess part of the problem is related to the product image path in the VM configuration. Some time ago the /stories had been eliminated and newer version of VM use the path images/virtuemart/product/ for storing product images. Maybe this would help a little bit, too: https://forum.virtuemart.net/index.php?topic=137514.0 (https://forum.virtuemart.net/index.php?topic=137514.0)

I did set up a new VM shop with version number 10289 a few days ago and had no problem with the images. However, I can confirm that the 'Displayed image subtitle' and 'Image Alt-Text' fields are not automatically filled with the image file name anymore, which probably is a bug. I usually ftp my images and then synchronize them with the button in the VM Tools. In this case the 'Displayed image subtitle' and 'Image Alt-Text' fields are still filled with the file name automatically (which I have to change afterwards).
Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: AH on March 26, 2020, 10:55:24 AM
Hi

Regarding alt-text (file_meta in the media table)

Uploading in media handler uses a "no-image-set" which can then be deleted or overwritten manually.

I use the image handling from the product images tab  -  upload file browse button (with none selected as radio)  -
- This function works and is the quickest option (for me at present)
- No alt-text is auto set (file_meta) using this method  - It has never been set and should not be set now
- Alt-data should be created manually to describe the image before saving - but note: that this will be used whenever the image is displayed - This is significant when the image is displayed on multiple products


Display-
For displaying images for products on a category page VM uses displayMediaThumb -

This will use the first none empty entry when "filling" the $file_alt - in this sequence.

1. file_meta
2. file_description
3. file_name
4. empty

As I have empty file_meta and file_description and I use a single image on multiple items I get the filename as a file_meta (alt-text) - when the category display is shown (Not ideal)

Product override
However at a single product level I override this behaviour and use the product name


if (empty ($this->product->images[0]->file_meta)) {
$this->product->images[0]->file_meta  = $this->product->product_name;
}





Title: Re: Can not upload product images after 3.6.11.10245 update
Post by: lostmail on March 31, 2020, 14:56:52 PM
Quote from: jenkinhill on March 23, 2020, 10:57:11 AM
And with the last beta release,   com_virtuemart.3.6.11.10289 (http://dev.virtuemart.net/attachments/1248/com_virtuemart.3.6.11.10289_package_or_extract.zip) ?   

Installed this one and now i get this error:
http://forum.virtuemart.net/index.php?topic=144602.0

But the single image upload seems to work here...(but the default "alt image text" is even here).