Welcome Guest! You need to login or register to make posts.

Notification

Icon
Error

Options
Go to last post Go to first unread
Bob_J  
#1 Posted : Friday, August 11, 2006 9:50:32 AM(UTC)
Bob_J

Rank: Member

Groups: Member
Joined: 3/20/2006(UTC)
Posts: 30

Is there a way, with the Java Uploader, to detect the size of the images before the person uploads? Specifically, we want people to always upload images that are 800x600 or larger, and if they are smaller, then pop-up a warning that says "Your images are smaller than the optimal size of 800x600" -- but not prevent them from uploading the smaller pics, if they really want to.
Alex Makhov  
#2 Posted : Saturday, August 12, 2006 2:26:18 PM(UTC)
Alex Makhov

Rank: Advanced Member

Groups:
Joined: 8/3/2003(UTC)
Posts: 998

Hello Bob,

I think the following properties would be helpful for you: UploadFileWidth Property, UploadFileHeight Property.

Edited by user Tuesday, February 19, 2008 1:13:07 PM(UTC)  | Reason: Not specified

Sincerely yours,
Alex Makhov

UserPostedImage Follow Aurigma on Twitter!
Bob_J  
#3 Posted : Wednesday, August 16, 2006 2:50:24 AM(UTC)
Bob_J

Rank: Member

Groups: Member
Joined: 3/20/2006(UTC)
Posts: 30

I must be doing something wrong -- I'm running the following bit of Javascript after all images have been selected (we're forcing them to upload no more and no less than 5; this bit of code doesn't run until all five have been selected):

Code:
for(i = 1; i <= 5; i++)
{
	vWidth = getImageUploader("ImageUploader").getUploadFileWidth(i);
	if(vWidth < 800)
		getSize = getSize + "Image: " + i + " " + vWidth + "\n";
}
alert(getSize);


It's correctly giving me the width for the first photo, but I'm getting 0 for all the others. What am I doing wrong?

Sample output:

Image: 1 512
Image: 2 0
Image: 3 0
Image: 4 0
Image: 5 0

Edited by user Tuesday, February 19, 2008 1:13:33 PM(UTC)  | Reason: Not specified

Bob_J  
#4 Posted : Thursday, August 17, 2006 1:26:01 AM(UTC)
Bob_J

Rank: Member

Groups: Member
Joined: 3/20/2006(UTC)
Posts: 30

I'm really stumped with this -- I followed the instructions in your manual for UploadFileWidth Property; I can't even get the width property for any images past the first one, even if I do something simple like:

var vWidth = getImageUploader("ImageUploader").getUploadFileWidth(2);

They all come up as zero.

EDIT: Never mind -- it's suddenly working now. I don't know why, as I haven't made any changes to the code, but whatever.
Gini  
#5 Posted : Thursday, August 17, 2006 2:38:48 AM(UTC)
Gini

Rank: Member

Groups: Member
Joined: 8/16/2006(UTC)
Posts: 9

Hi

Can u please tell me what upload component you are using with Image Uploader4.0
Gini
Alex Makhov  
#6 Posted : Thursday, August 17, 2006 7:58:45 PM(UTC)
Alex Makhov

Rank: Advanced Member

Groups:
Joined: 8/3/2003(UTC)
Posts: 998

Hello,

We have reproduced the bug. The problem occurred when all the thumbnails were small and EXIF thumbnails have been used. The fix will be available in the near release.
Sincerely yours,
Alex Makhov

UserPostedImage Follow Aurigma on Twitter!
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.