Pergunta

Do we have any functionality available in Apache Wicket for file uploads, where i can have different properties like file object,content Type,file name readily available.

Foi útil?

Solução

Just use a FileUploadField, mark the form as multiplePart and when the form is submitted you can access the FileUpload which has properties getSize(), getContentType() and getClientFileName().

More info & example: http://wicket.apache.org/apidocs/1.5/org/apache/wicket/markup/html/form/upload/FileUpload.html

http://www.mkyong.com/wicket/wicket-file-upload-example/

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top