voyent
File Upload - Page Refresh Needed  XML
Forum Index -> Components
Author Message
jmind

Joined: 07/Jul/2008 00:00:00
Messages: 54
Offline


When i upload a file the page won't refresh. I have to manually refresh the page with the F5 button. If i set com.icesoft.faces.synchronousUpdate to false then the page is refreshed as desired, but i need to keep that param set to true because of the Network Connection Interrupted message which would pop up too often.

Any suggestion will be appreciated

regards

italian coder
edykory


Joined: 27/Nov/2006 00:00:00
Messages: 332
Offline


I don't think com.icesoft.faces.synchronousUpdate=false should generate Network Connection Interrupted, unless you open more than one page (the Asynchronous mechanism keeps a connection blocked all the time and there's a 2 connection / server limit in windows). I use it all the time (since we need server push) and never had any problems and I have a couple of projects deployed with tens of simultaneous users over quite low bandwidth (300-500kbs).

Eduard
elena_villalon

Joined: 26/Nov/2008 00:00:00
Messages: 4
Offline


I think that in your web.xml you change your connection timeout as
<param-name>com.icesoft.faces.connectionTimeout</param-name>
<param-value>300000</param-value>
THis should get out of your problems
EV
edykory


Joined: 27/Nov/2006 00:00:00
Messages: 332
Offline


it's not really so ... the connectionTimeout parameter helps only if you have long serverside actions (that is, if generating the response upon a request takes more than 1 min or so) ...

Please check the IceFaces documentation (the 2 PDFs in the IceFaces distribution) and you'll see the meaning of all connection/hear beating related parameters.

Eduard
mark.collette


Joined: 07/Feb/2005 00:00:00
Messages: 1692
Offline


If you have no input fields in the same form as the inputFile component, it should have no side-effects to set submitOnUpload="postUpload" on the inputFile component. This will cause the page to refresh after the file upload.
[Email]
jmind

Joined: 07/Jul/2008 00:00:00
Messages: 54
Offline


mark.collette wrote:
If you have no input fields in the same form as the inputFile component, it should have no side-effects to set submitOnUpload="postUpload" on the inputFile component. This will cause the page to refresh after the file upload. 


submitOnUpload="postUpload" worked for me. thanks
cooreys

Joined: 11/Oct/2009 00:00:00
Messages: 1
Offline


Used a javascript refresh of frame if it dissapeared e.g.

//Work around for ICEFACES BUG #ICE-4474
//Bug kicks in after 5 seconds delay.
// Relies on updated jar downloaded from http://www.icefaces.org/JForum/posts/list/15351.page
// to get the thumbnails images to always refresh.
function refreshPhotoFrame()
{
setInterval("doRefreshPhotoFrame()", 7000);
}

function doRefreshPhotoFrame()
{
try
{
var f = document.getElementById('sightingForm:imageUpload:uploadFrame');
if (f.contentWindow.document.body.innerHTML==""){
f.src=f.src;
}
}catch(e){}
}
 
Forum Index -> Components
Go to:   
Powered by JForum 2.1.7ice © JForum Team