iefixes.js
来自「颜色分辨 芯片TCS230 读取白色发光二极管的亮度及颜色植转化后输出」· JavaScript 代码 · 共 48 行
JS
48 行
// IE fix javascriptvar rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, '');if (rslt != null ) var version = Number(rslt[1]);else var version = 0;window.attachEvent("onload", hookit);function hookit() {// fixalpha(); relativeforfloats();}// png alpha transparency fixesfunction fixalpha(){ // bg if(version >= 5.5) { var logoa = document.getElementById('p-logo').firstChild; var bg = logoa.currentStyle.backgroundImage; if (bg.match(/\.png/i) != null){ var mypng = bg.substring(5,bg.length-2); logoa.style.backgroundImage = "none"; logoa.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+mypng+"', sizingMethod='crop')"; } }}// fix ie6 disappering float bugfunction relativeforfloats() { var bc = document.getElementById('bodyContent'); if (bc) { var tables = bc.getElementsByTagName('table'); var divs = bc.getElementsByTagName('div'); } setrelative(tables); setrelative(divs);}function setrelative (nodes) { var i = 0; while (i < nodes.length) { if(((nodes[i].style.float && nodes[i].style.float != ('none') || (nodes[i].align && nodes[i].align != ('none'))) && (!nodes[i].style.position || nodes[i].style.position != 'relative'))) { nodes[i].style.position = 'relative'; } i++; }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?