Fixed thumbnail problem with multiple files
This commit is contained in:
parent
3fd34db37c
commit
4aa41653be
1 changed files with 3 additions and 3 deletions
|
@ -114,12 +114,12 @@ $(function()
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var img = postDom.find('img')
|
||||||
var reader = new FileReader();
|
var reader = new FileReader();
|
||||||
reader.onload = (function(theFile)
|
reader.onload = (function(theFile, img)
|
||||||
{
|
{
|
||||||
return function(e)
|
return function(e)
|
||||||
{
|
{
|
||||||
var img = postDom.find('img')
|
|
||||||
/*img.css('max-width', img.css('width'));
|
/*img.css('max-width', img.css('width'));
|
||||||
img.css('max-height', img.css('height'));
|
img.css('max-height', img.css('height'));
|
||||||
img.css('width', 'auto');
|
img.css('width', 'auto');
|
||||||
|
@ -127,7 +127,7 @@ $(function()
|
||||||
img.css('background-image', 'none');
|
img.css('background-image', 'none');
|
||||||
img.attr('src', e.target.result);
|
img.attr('src', e.target.result);
|
||||||
};
|
};
|
||||||
})(file);
|
})(file, img);
|
||||||
reader.readAsDataURL(file);
|
reader.readAsDataURL(file);
|
||||||
}
|
}
|
||||||
$('#upload-step2').fadeIn(function()
|
$('#upload-step2').fadeIn(function()
|
||||||
|
|
Loading…
Reference in a new issue