0

Hi,
I was wondering if it is possible to create thumbnails automaticly from images when they are uploaded to the server?I would need a seperate file for the thumbnails...
Does anybody have any clue of this?I was thinking in the direction of jquery but i dont know for sure :)
thx in advance

3
Contributors
4
Replies
5
Views
6 Years
Discussion Span
Last Post by Taywin
0

steel:

Your purpose is ambiguous to me. Let see a use case here.
1)A user request to upload an image to the server???
2)An upload file form is displayed
3)The user selects a file and submit
4)The file is uploaded on the server and a thumbnail of the image is created
5)After the upload, the page is refreshed and the image thumbnail is displayed???

Would steps above be the case? That's why it is ambiguous to me because I do not know how a user upload an image file, or has the image file been uploaded in the first place? Or else?

Edited by Taywin: n/a

0

SteelShark,

The answer is Yes, but it's not a JavaScript/DHTML/AJAX question.

Permanent reduction of full-sized images to make thumbnails is a server-side thing performed by (or via) eg. JSP/PHP/CGI - whichever is available to you.

You can, of course, serve unreduced full-sized images and use them as thumbnails by rendering them in the browser with <img width="xx" hieght="yy"> but that will increase page download time and waste bandwidth. Pages made this way can be horribly annoying for the user.

Airshow

Edited by Airshow: n/a

0

I have already created a perfect functioning script, that allows the user to select a file, and upload it to a given directory :)
So the only thing i need is, how to create a thumbnail from a given image?
Sorry if my question was a bit confusing :p

0

steel:

As Airshow said, it is server side script/program to deal with creating a new file. JavaScript is not allowed to do that. You may have to go to your server side technology to ask (unless it is PHP then it is on here).

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.