大圖移動問題
var percentX = left / objMark.offsetWidth;
var percentY = top / objMark.offsetHeight;
objBigBoxImage.style.left = -percentX * objBigBoxImage.offsetWidth ?+ "px";
objBigBoxImage.style.top = -percentY * objBigBoxImage.offsetHeight + "px";
這樣寫好像也能有同樣的效果,而且似乎好理解一點,是不是這樣會有什么問題呢
2016-04-14
能有什么問題!代碼分段