vendredi 29 juillet 2016

Data undefined in a library initialisation Javascript

I use dropzone library, when I load the page the item-id attribute is null, but after a click get a new value but in the initialisation remains null. How can I update the value in dropzone initialisation?

    $("div#client_documents").dropzone({
        url: '/clients/' + $('#rootwizard').attr('item-id') + '/documentsUpload', // $('#rootwizard').attr('item-id') is null 
        maxFilesize: 20,
        paramName: 'file',

     ...................

Aucun commentaire:

Enregistrer un commentaire