-
Bug
-
Resolution: Fixed
-
Normal
-
7.0.3, 7.0.5
-
Security Level: Jimmy
-
chrome 38, firefox
-
ZK 7.0.7
-
None
Problem Description
A forum user reported http://forum.zkoss.org/question/94362/upload-attribute-accept-multiple-file-extensions/
The syntax for "accept" attribute is described in http://books.zkoss.org/wiki/ZK_Component_Reference/Essential_Components/Button#Upload
Steps to Reproduce
- run the zul below
<zscript><![CDATA[ import org.zkoss.util.media.Media;; public void myProcessUpload(UploadEvent event){ System.out.println("uploaded"); Media media = event.getMedia(); System.out.println("uploaded "+media.getName()+", size:"+(media.getByteData().length/1024)+" k bytes"); } ]]> </zscript> <button label="file extension" upload="true,maxsize=-1,accept=.png|.pdf" onUpload="myProcessUpload(event)"/>
- click the button
Actual Result
popup dialog cannot display png and pdf file
Expected Result
filter both png and pdf files