I'm using CKFinder for Java version 2.4, and when I upload images, everything is working fine (i.e. images are stored in proper file location, thumbs are being generated in the _thumbs folder, etc), however, the preview images do not show up in the browser. I have created a custom class to dynamically set the BaseDir and BaseUrl - not sure if that could have something to do with it. I had to do that because I wanted to create a different folder for each user. Any thoughts on what to check?
-- Glen
Update: thumbnail file sizes are zero
Looked a little closer and realized that the thumbnail files are being created, but their file size is 0. That explains why they don't show up in the browser, but why would the file size be 0?
G
Implementing IBasePathBuilder
Here's my code - am I missing anything? By implementing this class and making the following setting in config.xml am I causing CKFinder to ignore all the rest of the stuff in config.xml (like the thumbnail settings perhaps)? Could this be the root of my problem?
<basePathBuilderImpl>atg.CDB.CDBPathBuilder</basePathBuilderImpl>
package atg.CDB;
import atg.nucleus.GenericService;
import atg.repository.RepositoryItem;
import atg.servlet.ServletUtil;
import javax.servlet.http.HttpServletRequest;
import com.ckfinder.connector.configuration.IBasePathBuilder;
public class CDBPathBuilder implements IBasePathBuilder {
public String getBaseDir(HttpServletRequest request) {
String profileId = getProfileId();
return "/work/atg/ATG10.1.2/home/doc/files/CDB/"+profileId+"/";
}
public String getBaseUrl(HttpServletRequest request) {
String profileId = getProfileId();
return "/dyn/dyn/files/CDB/"+profileId+"/";
}
public String getProfileId() {
RepositoryItem profile = ServletUtil.getCurrentUserProfile();
String profileId=null;
if(profile != null)
profileId = profile.getRepositoryId();
else
System.out.println("Error finding profileId in CDBPathBuilder");
return profileId;
}
}
thumbnail file sizes are zero
When I upload an image, the image is stored in the correct folder, and a thumbnail image is created, but the file size is zero. How can I debug what's going on?