I'm trying to get multiple instances of valum file uploader working on my site. It works great with one instance but anytime I loop over initialization code, wanting multiple buttons I don't see any buttons. Here's the code:
<cfoutput query="getTopics">
<script>
function createUploader(){
var uploader = new qq.FileUploader({
element: document.getElementById('file-uploader#refTopicID#'),
action: 'components/ProjectBean.cfc',
params: {method: 'Upload',
topicID: #refTopicID#,
count: #Evaluate("session.#refTopicAbv#Count")#,
topicName: '#refTopicAbv#'
},
encoding: 'multipart'
});
}
// in your app create uploader as soon as the DOM is ready
// don't wait for the window to load
window.onload = createUploader;
</script>
<div class="row" id="file-uploader#refTopicID#">
</div>
Any idea how to get multiple instance? Thanks in advance!