//上传经纬度
document.getElementById("file-input").onchange = function(img) {
imgFile = img;
var allFiles = imgFile.target.files;
var laltest="";
length_lal++;
var imgarr=new Array();
var tmpimg = allFiles[0];
imgarr[i]=allFiles[0];
var readImg = new FileReader();
readImg.readAsDataURL(tmpimg);
readImg.onload = function (readEvent){
var base64 = readEvent.target.result;
var appd = "<img src=""+base64+"" width="200px" height="200px">";
$("#image").append(appd);
};
EXIF.getData(tmpimg, function(){
var imgname=tmpimg.name;
var tagj=EXIF.getTag(tmpimg,'GPSLongitude');
var tagw=EXIF.getTag(tmpimg,'GPSLatitude');
var longitude=tagj[0]+tagj[1]/60+tagj[2]/60/60;
var latitude=tagw[0]+tagw[1]/60+tagw[2]/60/60;
lalinfo=lalinfo+imgname+":"+longitude+":"+latitude+",";
alert(lalinfo);
});
}