Default image upload return error: "Only web-standard images (jpg, gif, and png)..."

xaviercas - October 29, 2009 - 21:48
Project:ImageField
Version:6.x-3.2
Component:Miscellaneous
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed
Description

Drupal 6.14
File system Writable (public download method)
MySQL database 5.0.51a
PHP 5.2.10
Ubercart 6.x-2.0-rc3
Content Construction Kit (CCK) 6.x-2.5
FileField 6.x-3.2
ImageField 6.x-3.2
ImageCache 6.x-2.0-beta10

Hi,
I would like to have a default image if none are uploaded on a product node in ubercart.
I have been trying to upload a default image to imagefield on content node type: product (ubercart). I choose the file, tick the check box and save config. Each time the error msg "Only web-standard images (jpg, gif, and png)..." shows.
Tried different jpg and gifs (<10kb).
Set permissions to 777.
The image actually uploads. Nevertheless error keep showing.
Delete image from server, clear all cache, error msg disappear.
I have been trawling the net and cannot find a similar issue.
No other problem with imagefield otherwise.
Not a major problem, but really cant figure it out. Any idea?

Thanks. Xavier

#1

tic2000 - October 30, 2009 - 09:56

It seems that it checks the allowed extensions and wants only web standards ones. And the web standard is coded in an array $web_extensions = array('jpg', 'jpeg', 'gif', 'png');. So with the value like "gif jpg jpeg png bmp" for the "Permitted upload file extensions" field you will get an error because of the bmp extension.

#2

xaviercas - November 1, 2009 - 22:39
Status:active» fixed

Hi tic2000,

Great thank you. I removed 'bmp' from the 'Permitted upload file extensions' text box and everything works as it should (well, nearly see below). I wonder why the bitmap format was in the list at the first place. Anyway thank you for your help. Closing this issue.

Next issue which is unrelated to this one: the default image is not showing in the product nodes. Cleared caches, but no go. I will have a look at it.

#3

tic2000 - November 5, 2009 - 12:42

If I remember corectly, the setting is not retroactive. You have to re-save every node for the default image to appear.

#4

xaviercas - November 9, 2009 - 04:06

Hi, Thanks for your reply. I thought the same, however even creating a new node (product) without an image does not load the default image! Still a little stuck on that one.

#5

tic2000 - November 9, 2009 - 22:32

I don't know your case, is it working in garland theme? If it does the problem is in your modules/themes, if it doesn't... I don't know, it works for me :)

#6

System Message - November 23, 2009 - 22:40
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.