如何返回「summe」的值?謝謝!返回var的img.onload = function()
img.onload = function() {
orgWidth = this.width;
orgHeight = this.height;
factor = orgHeight/480 // 1400/480 = 2.916
calcWidth = orgWidth/factor // 1000/2.916 = 342.935
k++;
summe += calcWidth;
document.images[k].width = calcWidth;
}
alert(summe);
返回什麼? – Ryan 2011-12-26 18:51:36