-
1. Re: <rich:fileupload> rerendering problem
tungtrum17 Aug 1, 2012 4:45 AM (in response to mahi.rathaur)Don't need reRender message, rich:fileUpload support checking file size, file type, upload successful. You can see example code:
<rich:fileUpload id="uploadDoc1" style="width:100%;border:none;height:100%"
onuploadcomplete="self.parent.location.href='#{uploadController.time}'"
acceptedTypes="#{uploadController.type}"
uploadControlLabel="Upload"
addControlLabel="Chọn file"
clearAllControlLabel="Xóa hết"
clearControlLabel="Xóa"
cancelEntryControlLabel="Hủy"
doneLabel=""
sizeErrorLabel="Kích thước file không phù hợp."
transferErrorLabel="Lỗi xảy ra trong quá trình upload"
progressLabel="Uploading ..."
maxFilesQuantity="10"
fileUploadListener="#{uploadController.uploadDocListener}"
listHeight="108px"
allowFlash="true"
uploadListClass="uploadListClass">
<f:facet name="label">
<h:outputText value="Đã tải lên {_KB}KB từ {KB}KB --- {mm}:{ss}"></h:outputText>
</f:facet>
</rich:fileUpload>
-
2. Re: <rich:fileupload> rerendering problem
mahi.rathaur Aug 1, 2012 12:38 PM (in response to tungtrum17)acctually i hv to read file and save data to database.i m doing some validation on data and if validation is failed i hv to show that data to user.i m returning that data in a form of list on the page .for that i need to use this <a4j:support> component.
-
3. Re: <rich:fileupload> rerendering problem
tungtrum17 Aug 2, 2012 12:06 AM (in response to mahi.rathaur)I have idea can help you..
You can't save message in session... then on onuploadcomplete event (<rich:fileUpload)... You use jquery to display message for user
example....
<div class="infor"></div>
javascript....
$.post("message.jsp",function(data){
if(data!=null) {
$('.info').html(data);
});
in message.jsp file you can display session message...
Regards
-
4. Re: <rich:fileupload> rerendering problem
mahi.rathaur Aug 2, 2012 1:15 PM (in response to tungtrum17)thanks nguyen. it got it.its working now..