You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Martin Grigorov <mg...@apache.org> on 2012/11/14 10:51:38 UTC

Re: Wicket and file upload with blueimp jquery file upload

Hi,

I've just added a new article at
http://wicketinaction.com/2012/11/uploading-files-to-wicket-iresource/ that
shows how to integrate such JavaScript file upload widgets with Wicket.
I hope it is useful for you!


On Wed, Oct 24, 2012 at 1:54 PM, heapifyman <he...@gmail.com> wrote:

> Thanks. That helped a lot.
>
>
> 2012/10/16 Bas Gooren <ba...@iswd.nl>
>
> > Behavior (wicket 1.5): http://pastebin.com/WUHsiRL2
> > instance.js (to initialize uploadify): http://pastebin.com/jGSwzHMN
> >
> > Mount it in Application.init() with:
> >
> > // Allow uploads through uploadify
> > mount( new UploadifyBehavior.Uploader( "/uploadify" ) );
> >
> > Use it like this:
> >
> > component.add( new UploadifyBehavior()
> >             {
> >
> >                 @Override
> >                 protected void onUpload( UploadInfo info,
> > AjaxRequestTarget target )
> >                 {
> >                     // Handle upload any way you like, and replace stuff
> > in this ajax request
> >                 }
> >
> >             } );
> >
> >
> > Met vriendelijke groet,
> > Kind regards,
> >
> > Bas Gooren
> >
> > Op 16-10-2012 19:09, schreef heapifyman:
> >
> >> Thanks.
> >> Would you mind sharing the mounted resource's code? I'm not completely
> >> sure
> >> how to implement that.
> >>
> >>
> >> 2012/10/16 Bas Gooren <ba...@iswd.nl>
> >>
> >>  Hi!
> >>>
> >>> We use a different uploader (uploadify), but the basics are the same.
> >>>
> >>> What we've built for this is a behavior which renders the UI for the
> >>> uploader, and handles ajax callbacks.
> >>>
> >>> The uploader uploads to a mounted resource (e.g. at /uploadify), which
> >>> has
> >>> an internal cache (UUID => FileInfo).
> >>> After a successful upload, the upload resource returns the UUID;
> >>> The javascript onComplete handler then calls the ajax behavior with the
> >>> UUID parameter, which allows other components in the page to respond to
> >>> the
> >>> upload.
> >>>
> >>> To prevent overflow in the uploader cache we use a map with a maximum
> >>> size
> >>> which evicts old entries on overflow.
> >>>
> >>> Met vriendelijke groet,
> >>> Kind regards,
> >>>
> >>> Bas Gooren
> >>>
> >>> Op 16-10-2012 12:59, schreef heapifyman:
> >>>
> >>>   Not sure if I understand.
> >>>
> >>>> As far as I got it, the upload plugin requires some "web service" that
> >>>> accepts POST and DELETE requests to add/remove uploaded files.
> >>>> Doing that is no problem, I guess.
> >>>> But how to I link this with the current user's wicket session so that
> I
> >>>> know which files the users uploaded when finally the form is
> submitted?
> >>>> I'm not sure if I'm using the right wording here. Hope you get the
> >>>> idea...
> >>>>
> >>>>
> >>>> 2012/10/16 Martin Grigorov <mg...@apache.org>
> >>>>
> >>>>   Hi,
> >>>>
> >>>>> Is it an option to upload to a IResource and store the uploaded data
> >>>>> the same way as if you'd do in the page ?
> >>>>>
> >>>>> On Tue, Oct 16, 2012 at 12:49 PM, heapifyman <he...@gmail.com>
> >>>>> wrote:
> >>>>>
> >>>>>  Hello,
> >>>>>>
> >>>>>> has anyone tried yet to integrate blueimp's jQuery File Upload
> >>>>>> http://blueimp.github.com/****jQuery-File-Upload/<
> http://blueimp.github.com/**jQuery-File-Upload/>
> >>>>>> <http://**blueimp.github.com/jQuery-**File-Upload/<
> http://blueimp.github.com/jQuery-File-Upload/>>with
> >>>>>> Wicket FileUpload?
> >>>>>>
> >>>>>> Especially in combination with additional input fields <input
> >>>>>> type=text">
> >>>>>> I'm kind of stuck because I'm not really sure where to point the
> >>>>>> jquery
> >>>>>> file upload's url param to and how to store the uploaded files in
> the
> >>>>>> wicket page for saving them when the complete form is submitted.
> >>>>>>
> >>>>>> Any help would be appreciated.
> >>>>>> Thanks
> >>>>>>
> >>>>>>
> >>>>> --
> >>>>> Martin Grigorov
> >>>>> jWeekend
> >>>>> Training, Consulting, Development
> >>>>> http://jWeekend.com
> >>>>>
> >>>>> ------------------------------****----------------------------**--**
> >>>>> ---------
> >>>>> To unsubscribe, e-mail: users-unsubscribe@wicket.**apa**che.org<
> http://apache.org>
> >>>>> <users-unsubscribe@**wicket.apache.org<
> users-unsubscribe@wicket.apache.org>
> >>>>> >
> >>>>>
> >>>>> For additional commands, e-mail: users-help@wicket.apache.org
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com <http://jweekend.com/>

Re: Wicket and file upload with blueimp jquery file upload

Posted by Pierre Goupil <go...@gmail.com>.
Thanks! Sorry for not having read it until the end! :-)


On Wed, Nov 14, 2012 at 11:03 AM, Martin Grigorov <mg...@apache.org>wrote:

> There is a link to my GitHub repo in the article.
>
>
> On Wed, Nov 14, 2012 at 12:00 PM, Pierre Goupil <goupilpierre@gmail.com
> >wrote:
>
> > Good morning,
> >
> > Would guys be kind and share these codes, please? Not re-inventing the
> > whell, you know.
> >
> > Thanks in advance & best regards,
> >
> > Pierre
> >
> >
> > On Wed, Nov 14, 2012 at 10:51 AM, Martin Grigorov <mgrigorov@apache.org
> > >wrote:
> >
> > > Hi,
> > >
> > > I've just added a new article at
> > >
> >
> http://wicketinaction.com/2012/11/uploading-files-to-wicket-iresource/that
> > > shows how to integrate such JavaScript file upload widgets with Wicket.
> > > I hope it is useful for you!
> > >
> > >
> > > On Wed, Oct 24, 2012 at 1:54 PM, heapifyman <he...@gmail.com>
> > wrote:
> > >
> > > > Thanks. That helped a lot.
> > > >
> > > >
> > > > 2012/10/16 Bas Gooren <ba...@iswd.nl>
> > > >
> > > > > Behavior (wicket 1.5): http://pastebin.com/WUHsiRL2
> > > > > instance.js (to initialize uploadify):
> http://pastebin.com/jGSwzHMN
> > > > >
> > > > > Mount it in Application.init() with:
> > > > >
> > > > > // Allow uploads through uploadify
> > > > > mount( new UploadifyBehavior.Uploader( "/uploadify" ) );
> > > > >
> > > > > Use it like this:
> > > > >
> > > > > component.add( new UploadifyBehavior()
> > > > >             {
> > > > >
> > > > >                 @Override
> > > > >                 protected void onUpload( UploadInfo info,
> > > > > AjaxRequestTarget target )
> > > > >                 {
> > > > >                     // Handle upload any way you like, and replace
> > > stuff
> > > > > in this ajax request
> > > > >                 }
> > > > >
> > > > >             } );
> > > > >
> > > > >
> > > > > Met vriendelijke groet,
> > > > > Kind regards,
> > > > >
> > > > > Bas Gooren
> > > > >
> > > > > Op 16-10-2012 19:09, schreef heapifyman:
> > > > >
> > > > >> Thanks.
> > > > >> Would you mind sharing the mounted resource's code? I'm not
> > completely
> > > > >> sure
> > > > >> how to implement that.
> > > > >>
> > > > >>
> > > > >> 2012/10/16 Bas Gooren <ba...@iswd.nl>
> > > > >>
> > > > >>  Hi!
> > > > >>>
> > > > >>> We use a different uploader (uploadify), but the basics are the
> > same.
> > > > >>>
> > > > >>> What we've built for this is a behavior which renders the UI for
> > the
> > > > >>> uploader, and handles ajax callbacks.
> > > > >>>
> > > > >>> The uploader uploads to a mounted resource (e.g. at /uploadify),
> > > which
> > > > >>> has
> > > > >>> an internal cache (UUID => FileInfo).
> > > > >>> After a successful upload, the upload resource returns the UUID;
> > > > >>> The javascript onComplete handler then calls the ajax behavior
> with
> > > the
> > > > >>> UUID parameter, which allows other components in the page to
> > respond
> > > to
> > > > >>> the
> > > > >>> upload.
> > > > >>>
> > > > >>> To prevent overflow in the uploader cache we use a map with a
> > maximum
> > > > >>> size
> > > > >>> which evicts old entries on overflow.
> > > > >>>
> > > > >>> Met vriendelijke groet,
> > > > >>> Kind regards,
> > > > >>>
> > > > >>> Bas Gooren
> > > > >>>
> > > > >>> Op 16-10-2012 12:59, schreef heapifyman:
> > > > >>>
> > > > >>>   Not sure if I understand.
> > > > >>>
> > > > >>>> As far as I got it, the upload plugin requires some "web
> service"
> > > that
> > > > >>>> accepts POST and DELETE requests to add/remove uploaded files.
> > > > >>>> Doing that is no problem, I guess.
> > > > >>>> But how to I link this with the current user's wicket session so
> > > that
> > > > I
> > > > >>>> know which files the users uploaded when finally the form is
> > > > submitted?
> > > > >>>> I'm not sure if I'm using the right wording here. Hope you get
> the
> > > > >>>> idea...
> > > > >>>>
> > > > >>>>
> > > > >>>> 2012/10/16 Martin Grigorov <mg...@apache.org>
> > > > >>>>
> > > > >>>>   Hi,
> > > > >>>>
> > > > >>>>> Is it an option to upload to a IResource and store the uploaded
> > > data
> > > > >>>>> the same way as if you'd do in the page ?
> > > > >>>>>
> > > > >>>>> On Tue, Oct 16, 2012 at 12:49 PM, heapifyman <
> > heapifyman@gmail.com
> > > >
> > > > >>>>> wrote:
> > > > >>>>>
> > > > >>>>>  Hello,
> > > > >>>>>>
> > > > >>>>>> has anyone tried yet to integrate blueimp's jQuery File Upload
> > > > >>>>>> http://blueimp.github.com/****jQuery-File-Upload/<
> > > > http://blueimp.github.com/**jQuery-File-Upload/>
> > > > >>>>>> <http://**blueimp.github.com/jQuery-**File-Upload/<
> > > > http://blueimp.github.com/jQuery-File-Upload/>>with
> > > > >>>>>> Wicket FileUpload?
> > > > >>>>>>
> > > > >>>>>> Especially in combination with additional input fields <input
> > > > >>>>>> type=text">
> > > > >>>>>> I'm kind of stuck because I'm not really sure where to point
> the
> > > > >>>>>> jquery
> > > > >>>>>> file upload's url param to and how to store the uploaded files
> > in
> > > > the
> > > > >>>>>> wicket page for saving them when the complete form is
> submitted.
> > > > >>>>>>
> > > > >>>>>> Any help would be appreciated.
> > > > >>>>>> Thanks
> > > > >>>>>>
> > > > >>>>>>
> > > > >>>>> --
> > > > >>>>> Martin Grigorov
> > > > >>>>> jWeekend
> > > > >>>>> Training, Consulting, Development
> > > > >>>>> http://jWeekend.com
> > > > >>>>>
> > > > >>>>>
> > > ------------------------------****----------------------------**--**
> > > > >>>>> ---------
> > > > >>>>> To unsubscribe, e-mail: users-unsubscribe@wicket.**apa**
> che.org<
> > > > http://apache.org>
> > > > >>>>> <users-unsubscribe@**wicket.apache.org<
> > > > users-unsubscribe@wicket.apache.org>
> > > > >>>>> >
> > > > >>>>>
> > > > >>>>> For additional commands, e-mail: users-help@wicket.apache.org
> > > > >>>>>
> > > > >>>>>
> > > > >>>>>
> > > > >>>>>
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Martin Grigorov
> > > jWeekend
> > > Training, Consulting, Development
> > > http://jWeekend.com <http://jweekend.com/>
> > >
> >
> >
> >
> > --
> > Le bonheur n'est pas une destination, mais une façon de voyager.
> >
> > Papa d'une petite Lou-Ann depuis le 30 juin.
> >
>
>
>
> --
> Martin Grigorov
> jWeekend
> Training, Consulting, Development
> http://jWeekend.com <http://jweekend.com/>
>



-- 
Le bonheur n'est pas une destination, mais une façon de voyager.

Papa d'une petite Lou-Ann depuis le 30 juin.

Re: Wicket and file upload with blueimp jquery file upload

Posted by Martin Grigorov <mg...@apache.org>.
There is a link to my GitHub repo in the article.


On Wed, Nov 14, 2012 at 12:00 PM, Pierre Goupil <go...@gmail.com>wrote:

> Good morning,
>
> Would guys be kind and share these codes, please? Not re-inventing the
> whell, you know.
>
> Thanks in advance & best regards,
>
> Pierre
>
>
> On Wed, Nov 14, 2012 at 10:51 AM, Martin Grigorov <mgrigorov@apache.org
> >wrote:
>
> > Hi,
> >
> > I've just added a new article at
> >
> http://wicketinaction.com/2012/11/uploading-files-to-wicket-iresource/that
> > shows how to integrate such JavaScript file upload widgets with Wicket.
> > I hope it is useful for you!
> >
> >
> > On Wed, Oct 24, 2012 at 1:54 PM, heapifyman <he...@gmail.com>
> wrote:
> >
> > > Thanks. That helped a lot.
> > >
> > >
> > > 2012/10/16 Bas Gooren <ba...@iswd.nl>
> > >
> > > > Behavior (wicket 1.5): http://pastebin.com/WUHsiRL2
> > > > instance.js (to initialize uploadify): http://pastebin.com/jGSwzHMN
> > > >
> > > > Mount it in Application.init() with:
> > > >
> > > > // Allow uploads through uploadify
> > > > mount( new UploadifyBehavior.Uploader( "/uploadify" ) );
> > > >
> > > > Use it like this:
> > > >
> > > > component.add( new UploadifyBehavior()
> > > >             {
> > > >
> > > >                 @Override
> > > >                 protected void onUpload( UploadInfo info,
> > > > AjaxRequestTarget target )
> > > >                 {
> > > >                     // Handle upload any way you like, and replace
> > stuff
> > > > in this ajax request
> > > >                 }
> > > >
> > > >             } );
> > > >
> > > >
> > > > Met vriendelijke groet,
> > > > Kind regards,
> > > >
> > > > Bas Gooren
> > > >
> > > > Op 16-10-2012 19:09, schreef heapifyman:
> > > >
> > > >> Thanks.
> > > >> Would you mind sharing the mounted resource's code? I'm not
> completely
> > > >> sure
> > > >> how to implement that.
> > > >>
> > > >>
> > > >> 2012/10/16 Bas Gooren <ba...@iswd.nl>
> > > >>
> > > >>  Hi!
> > > >>>
> > > >>> We use a different uploader (uploadify), but the basics are the
> same.
> > > >>>
> > > >>> What we've built for this is a behavior which renders the UI for
> the
> > > >>> uploader, and handles ajax callbacks.
> > > >>>
> > > >>> The uploader uploads to a mounted resource (e.g. at /uploadify),
> > which
> > > >>> has
> > > >>> an internal cache (UUID => FileInfo).
> > > >>> After a successful upload, the upload resource returns the UUID;
> > > >>> The javascript onComplete handler then calls the ajax behavior with
> > the
> > > >>> UUID parameter, which allows other components in the page to
> respond
> > to
> > > >>> the
> > > >>> upload.
> > > >>>
> > > >>> To prevent overflow in the uploader cache we use a map with a
> maximum
> > > >>> size
> > > >>> which evicts old entries on overflow.
> > > >>>
> > > >>> Met vriendelijke groet,
> > > >>> Kind regards,
> > > >>>
> > > >>> Bas Gooren
> > > >>>
> > > >>> Op 16-10-2012 12:59, schreef heapifyman:
> > > >>>
> > > >>>   Not sure if I understand.
> > > >>>
> > > >>>> As far as I got it, the upload plugin requires some "web service"
> > that
> > > >>>> accepts POST and DELETE requests to add/remove uploaded files.
> > > >>>> Doing that is no problem, I guess.
> > > >>>> But how to I link this with the current user's wicket session so
> > that
> > > I
> > > >>>> know which files the users uploaded when finally the form is
> > > submitted?
> > > >>>> I'm not sure if I'm using the right wording here. Hope you get the
> > > >>>> idea...
> > > >>>>
> > > >>>>
> > > >>>> 2012/10/16 Martin Grigorov <mg...@apache.org>
> > > >>>>
> > > >>>>   Hi,
> > > >>>>
> > > >>>>> Is it an option to upload to a IResource and store the uploaded
> > data
> > > >>>>> the same way as if you'd do in the page ?
> > > >>>>>
> > > >>>>> On Tue, Oct 16, 2012 at 12:49 PM, heapifyman <
> heapifyman@gmail.com
> > >
> > > >>>>> wrote:
> > > >>>>>
> > > >>>>>  Hello,
> > > >>>>>>
> > > >>>>>> has anyone tried yet to integrate blueimp's jQuery File Upload
> > > >>>>>> http://blueimp.github.com/****jQuery-File-Upload/<
> > > http://blueimp.github.com/**jQuery-File-Upload/>
> > > >>>>>> <http://**blueimp.github.com/jQuery-**File-Upload/<
> > > http://blueimp.github.com/jQuery-File-Upload/>>with
> > > >>>>>> Wicket FileUpload?
> > > >>>>>>
> > > >>>>>> Especially in combination with additional input fields <input
> > > >>>>>> type=text">
> > > >>>>>> I'm kind of stuck because I'm not really sure where to point the
> > > >>>>>> jquery
> > > >>>>>> file upload's url param to and how to store the uploaded files
> in
> > > the
> > > >>>>>> wicket page for saving them when the complete form is submitted.
> > > >>>>>>
> > > >>>>>> Any help would be appreciated.
> > > >>>>>> Thanks
> > > >>>>>>
> > > >>>>>>
> > > >>>>> --
> > > >>>>> Martin Grigorov
> > > >>>>> jWeekend
> > > >>>>> Training, Consulting, Development
> > > >>>>> http://jWeekend.com
> > > >>>>>
> > > >>>>>
> > ------------------------------****----------------------------**--**
> > > >>>>> ---------
> > > >>>>> To unsubscribe, e-mail: users-unsubscribe@wicket.**apa**che.org<
> > > http://apache.org>
> > > >>>>> <users-unsubscribe@**wicket.apache.org<
> > > users-unsubscribe@wicket.apache.org>
> > > >>>>> >
> > > >>>>>
> > > >>>>> For additional commands, e-mail: users-help@wicket.apache.org
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >>>>>
> > > >
> > >
> >
> >
> >
> > --
> > Martin Grigorov
> > jWeekend
> > Training, Consulting, Development
> > http://jWeekend.com <http://jweekend.com/>
> >
>
>
>
> --
> Le bonheur n'est pas une destination, mais une façon de voyager.
>
> Papa d'une petite Lou-Ann depuis le 30 juin.
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com <http://jweekend.com/>

Re: Wicket and file upload with blueimp jquery file upload

Posted by Pierre Goupil <go...@gmail.com>.
Good morning,

Would guys be kind and share these codes, please? Not re-inventing the
whell, you know.

Thanks in advance & best regards,

Pierre


On Wed, Nov 14, 2012 at 10:51 AM, Martin Grigorov <mg...@apache.org>wrote:

> Hi,
>
> I've just added a new article at
> http://wicketinaction.com/2012/11/uploading-files-to-wicket-iresource/that
> shows how to integrate such JavaScript file upload widgets with Wicket.
> I hope it is useful for you!
>
>
> On Wed, Oct 24, 2012 at 1:54 PM, heapifyman <he...@gmail.com> wrote:
>
> > Thanks. That helped a lot.
> >
> >
> > 2012/10/16 Bas Gooren <ba...@iswd.nl>
> >
> > > Behavior (wicket 1.5): http://pastebin.com/WUHsiRL2
> > > instance.js (to initialize uploadify): http://pastebin.com/jGSwzHMN
> > >
> > > Mount it in Application.init() with:
> > >
> > > // Allow uploads through uploadify
> > > mount( new UploadifyBehavior.Uploader( "/uploadify" ) );
> > >
> > > Use it like this:
> > >
> > > component.add( new UploadifyBehavior()
> > >             {
> > >
> > >                 @Override
> > >                 protected void onUpload( UploadInfo info,
> > > AjaxRequestTarget target )
> > >                 {
> > >                     // Handle upload any way you like, and replace
> stuff
> > > in this ajax request
> > >                 }
> > >
> > >             } );
> > >
> > >
> > > Met vriendelijke groet,
> > > Kind regards,
> > >
> > > Bas Gooren
> > >
> > > Op 16-10-2012 19:09, schreef heapifyman:
> > >
> > >> Thanks.
> > >> Would you mind sharing the mounted resource's code? I'm not completely
> > >> sure
> > >> how to implement that.
> > >>
> > >>
> > >> 2012/10/16 Bas Gooren <ba...@iswd.nl>
> > >>
> > >>  Hi!
> > >>>
> > >>> We use a different uploader (uploadify), but the basics are the same.
> > >>>
> > >>> What we've built for this is a behavior which renders the UI for the
> > >>> uploader, and handles ajax callbacks.
> > >>>
> > >>> The uploader uploads to a mounted resource (e.g. at /uploadify),
> which
> > >>> has
> > >>> an internal cache (UUID => FileInfo).
> > >>> After a successful upload, the upload resource returns the UUID;
> > >>> The javascript onComplete handler then calls the ajax behavior with
> the
> > >>> UUID parameter, which allows other components in the page to respond
> to
> > >>> the
> > >>> upload.
> > >>>
> > >>> To prevent overflow in the uploader cache we use a map with a maximum
> > >>> size
> > >>> which evicts old entries on overflow.
> > >>>
> > >>> Met vriendelijke groet,
> > >>> Kind regards,
> > >>>
> > >>> Bas Gooren
> > >>>
> > >>> Op 16-10-2012 12:59, schreef heapifyman:
> > >>>
> > >>>   Not sure if I understand.
> > >>>
> > >>>> As far as I got it, the upload plugin requires some "web service"
> that
> > >>>> accepts POST and DELETE requests to add/remove uploaded files.
> > >>>> Doing that is no problem, I guess.
> > >>>> But how to I link this with the current user's wicket session so
> that
> > I
> > >>>> know which files the users uploaded when finally the form is
> > submitted?
> > >>>> I'm not sure if I'm using the right wording here. Hope you get the
> > >>>> idea...
> > >>>>
> > >>>>
> > >>>> 2012/10/16 Martin Grigorov <mg...@apache.org>
> > >>>>
> > >>>>   Hi,
> > >>>>
> > >>>>> Is it an option to upload to a IResource and store the uploaded
> data
> > >>>>> the same way as if you'd do in the page ?
> > >>>>>
> > >>>>> On Tue, Oct 16, 2012 at 12:49 PM, heapifyman <heapifyman@gmail.com
> >
> > >>>>> wrote:
> > >>>>>
> > >>>>>  Hello,
> > >>>>>>
> > >>>>>> has anyone tried yet to integrate blueimp's jQuery File Upload
> > >>>>>> http://blueimp.github.com/****jQuery-File-Upload/<
> > http://blueimp.github.com/**jQuery-File-Upload/>
> > >>>>>> <http://**blueimp.github.com/jQuery-**File-Upload/<
> > http://blueimp.github.com/jQuery-File-Upload/>>with
> > >>>>>> Wicket FileUpload?
> > >>>>>>
> > >>>>>> Especially in combination with additional input fields <input
> > >>>>>> type=text">
> > >>>>>> I'm kind of stuck because I'm not really sure where to point the
> > >>>>>> jquery
> > >>>>>> file upload's url param to and how to store the uploaded files in
> > the
> > >>>>>> wicket page for saving them when the complete form is submitted.
> > >>>>>>
> > >>>>>> Any help would be appreciated.
> > >>>>>> Thanks
> > >>>>>>
> > >>>>>>
> > >>>>> --
> > >>>>> Martin Grigorov
> > >>>>> jWeekend
> > >>>>> Training, Consulting, Development
> > >>>>> http://jWeekend.com
> > >>>>>
> > >>>>>
> ------------------------------****----------------------------**--**
> > >>>>> ---------
> > >>>>> To unsubscribe, e-mail: users-unsubscribe@wicket.**apa**che.org<
> > http://apache.org>
> > >>>>> <users-unsubscribe@**wicket.apache.org<
> > users-unsubscribe@wicket.apache.org>
> > >>>>> >
> > >>>>>
> > >>>>> For additional commands, e-mail: users-help@wicket.apache.org
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>>
> > >
> >
>
>
>
> --
> Martin Grigorov
> jWeekend
> Training, Consulting, Development
> http://jWeekend.com <http://jweekend.com/>
>



-- 
Le bonheur n'est pas une destination, mais une façon de voyager.

Papa d'une petite Lou-Ann depuis le 30 juin.

Re: Wicket and file upload with blueimp jquery file upload

Posted by Raul <ra...@netwie.com>.
I solved the problems I had, modifying the main.js file of the demo, as
follows.

$(function () {
    'use strict';

    $('#${componentMarkupId}').fileupload({
        url: '${url}',
        paramName: '${paramName}',
        singleFileUploads: true,
        maxFileSize: 5000000,
        acceptFileTypes: /(\.|\/)(gif|jpe?g|png)$/i,
        process: [
            {
                action: 'load',
                fileTypes: /^image\/(gif|jpeg|png)$/,
                maxFileSize: 20000000 // 20MB
            },
            {
                action: 'resize',
                maxWidth: 1440,
                maxHeight: 900
            },
            {
                action: 'save'
            }
        ]
    });
});




--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-and-file-upload-with-blueimp-jquery-file-upload-tp4653007p4653938.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket and file upload with blueimp jquery file upload

Posted by Martin Grigorov <mg...@apache.org>.
On Thu, Nov 15, 2012 at 4:57 PM, Raul <ra...@netwie.com> wrote:

> Thanks for the demo, everything works fine except for some problems I've
> found in the configuration, for example, the demo comes with the option
> (previewSourceFileTypes: / ^ image \ / (gif | jpeg | png) $ /,). But really
> allow to upload all types of files.
>
>
This setting is supported only by modern browsers (HTML5).


> On the other hand (and this is important to me), when I upload multiple
> files at once, only shows the bar and the buttons for the first file. And
> should display them at all.
>
>
As I said at the end of the article - I am disappointed from the widget.
Its docs do not explain all the hidden requirements for the UI part of it.
If you fix these issues then I'll be happy to apply your improvements.


>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Wicket-and-file-upload-with-blueimp-jquery-file-upload-tp4653007p4653903.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>


-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com <http://jweekend.com/>

Re: Wicket and file upload with blueimp jquery file upload

Posted by Raul <ra...@netwie.com>.
Thanks for the demo, everything works fine except for some problems I've
found in the configuration, for example, the demo comes with the option
(previewSourceFileTypes: / ^ image \ / (gif | jpeg | png) $ /,). But really
allow to upload all types of files.

On the other hand (and this is important to me), when I upload multiple
files at once, only shows the bar and the buttons for the first file. And
should display them at all.





--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-and-file-upload-with-blueimp-jquery-file-upload-tp4653007p4653903.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org