Hey Adrian, 2009/9/1 Adrian Sutherland <[email protected]>: > Hi > > I was just using WFileUpload and have a couple of question also. > > 1. It works fine for "happy days" - but what happens if the user > inputs a filename that does not exist. At the moment it seems to give > a javascript error (access denied) - would be good if it threw a event
I tried this with Firefox on linux and IE on windows: with Firefox it simply uploads an empty file, with IE it refuses me to input an non-existing file. What browser/platform do you see this javascript error ? > like it does for "file to large" ...? If no file name is entered at > all it seems to silently fail (again it would be good if it raised an > error event). That is a silly regression, I opened a ticket for it a about a week ago (http://redmine.webtoolkit.eu/issues/show/53). > 2. How do you configure the max file size - apologies if this is > documented somewhere! <max-request-size> in wt_config.xml > Other suggestions: > > - perhaps we should also have a "file upload started" event - this > would avoid doubt as to if the file transfer was in progress (and > allow the screen to be updated accordingly). For an AJAX session, starting is always triggered yourself using WFileUpload::upload(), no ? > - I think we perhaps should have a single completion event with a > status code indicated success or type of failure? Or better the status > code could be got via a class method. I think that is a fair suggestion, the API is a bit messy (and it seems even more messy because empty files were broken). > - I tried to do a upload->disable() - which does not exist. I wanted > to disable the field while an update was in progress. Perhaps it does > it implicitly anyway? The disabled tag is not interpreted correctly on some browser (e.g. Safari), so it would not work in general. We would need to investigate what is exactly allows from a security point of view, but perhaps hiding (and replacing with a text "Upload in progress" is the most likely thing to work. Regards, koen ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ witty-interest mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/witty-interest
