You are making this call before anything has been rendered, hence the selector will fail if the #logoUpload is not directly on the page. You should create an upload view and then call this code in the didInsertElement function of the view.
How to use Uplodify.js with Ember.js
-
31-05-2022 - |
Pergunta
I'm creatinga n app using Ember.js and Ineed to upload files in my app for that I've to use uplodify.js I know how to use uplodify.js in the traditional way but the problem is how can i use the uplodify.js in a app constructed by Ember.js. my current code is given below I know its not correct
Wizard = Em.Application.create({
ready: function () {
$('#logoUpload').uploadify({
'swf': '/Assets/Uplodify/uploadify.swf',
'uploader': 'Business/FileUpload',
'buttonText': 'Upload new photo',
'cancelImg': '/Assets/Uplodify/cancel.png'
});
}
});
Solução
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow