KonaKart Community Forum

Installation / Configuration => Configuration of KonaKart => Topic started by: iamcp on November 09, 2007, 08:55:32 pm

Title: Cannot load images
Post by: iamcp on November 09, 2007, 08:55:32 pm
Hello,
Thank you for a wonderful cart to use for us. I have installed Konakart in my machine and I'm trying to upload images for a new product I want to add using konakartadmin package, but konakart is throwing an exception while I tried to do that.

Application complaints about "Empty file specified for upload" but the image file is not empty.

In the image path I give subdirectry/imagename.gif under images directory.

In the select image text box I give the imagename.gif.

In image1 testbox I give some name for description.

Does anyone has any idea why this is happening?

Thanks in advance


Here is the error

09-Nov 15:48:01 INFO  (FileUpload.java:processUploadedFile:153) Upload File imgB
asePath = C:/Konakart1/webapps/konakart/images  imgPath = matrox/mg200mms
.gif
java.lang.Exception: Empty file specified for upload
        at com.konakartadmin.servlet.FileUpload.processUploadedFile(FileUpload.j
ava:198)
        at com.konakartadmin.servlet.FileUpload.doPost(FileUpload.java:86)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:252)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:173)

Title: Re: Cannot load images
Post by: pete on November 09, 2007, 09:25:26 pm
Hi iamcp,

First of all please check that you've read the help on that images page of the admin app - it contains some useful information for loading images.

In image1 you must put the location of the image file that you uploaded not a description (the full file location is "Image base Path" plus the location you specify in this field).

Did you browse for the filename of the new image?  Is there a valid filename in the select file textbox?

Regards - Pete
Title: Re: Cannot load images
Post by: iamcp on November 09, 2007, 10:06:30 pm
Thank you for the advice, I was able to solve the issue.
But now I have 4 images for a particular product in the Admin app, but when a user tries to view the same product, only one image(first) is visible in the browser . Do i have to enable anything to view all 4 images from the customer side?

Thanks in advance
Title: Re: Cannot load images
Post by: pete on November 09, 2007, 10:16:45 pm
Hi iamcp,

You have to edit the JSP and add prod.getImage2(), prod.getImage3() etc. where you want to display the other images. The default application that we ship only displays one image.

Regards - Pete
Title: Re: Cannot load images
Post by: iamcp on November 28, 2007, 08:02:37 pm
I have done it and it worked like a charm, thanks for the post.
iamcp