如何构建电子商务网站,图片上传分享平台,东莞市网络seo推广怎么样,昆山做网站哪家好HTML 显示器纯色亮点检测工具 相关资源文件已经打包成html等文件#xff0c;可双击直接运行程序#xff0c;且文章末尾已附上相关源码#xff0c;以供大家学习交流#xff0c;博主主页还有更多Html相关程序案例#xff0c;秉着开源精神的想法#xff0c;望大家喜欢#…HTML 显示器纯色亮点检测工具 相关资源文件已经打包成html等文件可双击直接运行程序且文章末尾已附上相关源码以供大家学习交流博主主页还有更多Html相关程序案例秉着开源精神的想法望大家喜欢点个关注不迷路 1. 简介
纯色循环显示HTML家里经常买显示器需要测试亮点坏点 这个是用浏览器技术做的纯色亮点测试网页工具。 用浏览器打开后按F11进全屏一直换显示器。
使用方式 拖进浏览器按下F11快捷键进入全屏退出也是F11。
闪烁时间更改
window.setInterval(swichcolor, 1000);最后里两行 , 这里是毫秒. 1秒1000毫秒 改好刷新就可以用了.
2. 运行效果 3. 相关源码
!DOCTYPE html
html langenheadmeta charsetUTF-8meta nameviewport contentwidthdevice-width, initial-scale1.0title显示器测试-每秒自动切换颜色/title
/headbody styleheight: 100%;width: 100%;onLoadjavascript:window.resizeTo(screen.availWidth,screen.availHeight);window.moveTo(0,0)scriptfunction formatDate(date) {var date new Date(Date.now());var YY date.getFullYear() -;var MM (date.getMonth() 1 10 ? 0 (date.getMonth() 1) : date.getMonth() 1) -;var DD (date.getDate() 10 ? 0 (date.getDate()) : date.getDate());var hh (date.getHours() 10 ? 0 date.getHours() : date.getHours()) :;var mm (date.getMinutes() 10 ? 0 date.getMinutes() : date.getMinutes()) :;var ss (date.getSeconds() 10 ? 0 date.getSeconds() : date.getSeconds());return YY MM DD hh mm ss;}var color 0;var ci 0;function swichcolor() {switch (color) {case 0:document.getElementsByTagName(body)[0].style.backgroundColor #000000;color 1;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:黑色);break;case 1:document.getElementsByTagName(body)[0].style.backgroundColor #FF0000;color 2;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:红色);break;case 2:document.getElementsByTagName(body)[0].style.backgroundColor #00FF00;color 3;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:绿色);break;case 3:document.getElementsByTagName(body)[0].style.backgroundColor #0000FF;color 4;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:蓝色);break;case 4:document.getElementsByTagName(body)[0].style.backgroundColor #FFFF00;color 5;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:黄色);break;case 5:document.getElementsByTagName(body)[0].style.backgroundColor #00FFFF;color 6;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:青色);break;case 6:document.getElementsByTagName(body)[0].style.backgroundColor #FF00FF;color 7;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:紫红色);break;case 7:document.getElementsByTagName(body)[0].style.backgroundColor #C0C0C0;color 8;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:灰色);break;case 8:document.getElementsByTagName(body)[0].style.backgroundColor #FFFFFF;color 0;console.log(当前时间${formatDate()},脚本已经执行了${ci}次,当前:白色);break;default:break;}ci 1;}window.setInterval(swichcolor, 1000);/script
/body
/html