var switchTo5x=true; stLight.options({publisher: "daefb5fc-5bce-4da6-b47b-5148ed50db65", doNotHash: false, doNotCopy: false, hashAddressBar: false}); window.onload = function() { var img = document.getElementById('img'), /** * 圖片按比例自適應縮放 * @param img {Element} 用戶上傳的圖片 * @param maxWidth {Number} 預覽區域的最大寬度 * @param maxHeight {Number} 預覽區域的最大高度 */ resizeImg = function(img, maxWidth, maxHeight){ var w = img.width, h = img.height; // 當圖片比預覽區域小時不做任何改變 if(w < maxWidth && h < maxHeight) return; // 當實際圖片比例大于預覽區域寬高比例時 // 縮放圖片寬度,反之縮放圖片寬度 w/h > maxWidth/maxHeight ? img.width = maxWidth : img.height = maxHeight; }; resizeImg(img, 600, 300); }

Home > Press Area > Market Trend

  • Pegatron to be primary assembler of budget iPhone

    Apple will use Pegatron — not Foxconn — as its primary assembler for the company’s new low-cost iPhone “expected to be offered later this year,” according to a new report. A rival of Foxconn, Pegatron was a “minor producer” of iPhones in 2011 and also made iPad minis last year. Sources say Apple decided to use Pegatron to diversify its manufacturing after Foxconn had issues with scratches on the iPhone 5’s metal casing, and because Apple is expanding its product lines. While some claim Pegatron will accept smaller profits to produce Apple products, neither company has commented.[via ilounge