Z30-dynaImage.zul
{{IS_NOTE
Purpose:
Description:
History:
Thu Mar 13 11:24:31 TST 2008, Created by jumperchen
}}IS_NOTE
Copyright (C) 2008 Potix Corporation. All Rights Reserved.
{{IS_RIGHT
}}IS_RIGHT
-->
It is correct, if you can see the image file.
Also, try to click the invalidate button to see if it is still OK.
The content of image is created by AMedia(InputStream)
import javax.servlet.ServletContext;
import org.zkoss.web.fn.*;
ServletContext context = ServletFns.getCurrentServletContext();
java.io.FileInputStream fis = new java.io.FileInputStream(context.getRealPath("/img") + "/sun.jpg");
org.zkoss.image.Image media = new org.zkoss.image.AImage("sun.jpg",fis);
img.setContent(media);