Angular js Image upload how to check width and height example my withd=200 and heidht =200 if give more than pixel its show be error how can i us it if i try some thing can solve it
HTML
JS
$scope.fileList1 = [];
$scope.add1 = function(file1) {
console.log(file1);
for (var i = 0; i < file1.length; i++) {
if (file1[i].type == 'image/jpeg' || file1[i].type == 'image/jpg' || file1[i].type == 'image/tif' || file1[i].type == 'image/tiff') {
var item = {
name: file1[i].name,
file: file1[i]
};
$scope.fileList1.push(item);
var f = file1[i],
r = new FileReader();
console.log($scope.fileList1);
r.onloadend = function(e) {
}
r.readAsDataURL(f);
} else {
$('#file1').val('');
Notify.alert('Upload only .jpeg,jpg,tiff,tif format file', {
status: 'warning',
pos: 'top-right',
timeout: 3000
});
}
}
};
JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)