[eluser]macron[/eluser]
Hi
I'm doing this
Code:
->iupload('img','Add image',FALSE,array('class' => 'image'))
and in a js file I'm binding a clickevent to an ancor that injects another input type file so I can add several images via the form
Code:
$(function(){
$('a.button').bind('click', function(event){
// add image label and input
$('<label for="img" class="left"> </label><input type="file" name="img" value="" id="img" class="image" /><br />').insertBefore('#last');
// loop through all input[file] and rename to img1, img2, img3 ...
$("input.image").attr("name", function (arr) {
return "img" + arr;
})
;
});
});
As you can see I'm renaming the input to img1, img2, img3 ... but I never get access to these via
Code:
$this->form->get_post(TRUE);
I only get access to the org img and that one is set to false. That part I do understand as no element is now just name img but img1, img2...
What am I doing wrong here?
Fantastic lib though. Saves me a huge amount of time