爱易网
IT新闻
IT新闻
爱易资讯
网站搭建
云虚拟主机教程
云服务器教程
Apache教程
IIS教程
Nginx教程
网站策划
站长文章
推广教程
淘宝客教程
网页设计
HTML教程
XHTML教程
CSS教程
HTML5教程
CSS3教程
JavaSript基础
JQuery教程
Node.js教程
前端技术
Ajax教程
Js特效
Xml教程
平面设计
页面UI设计
photoshop教程
程序开发
AI人工智能
Asp教程
Php教程
Asp.Net教程
Net Core教程
C#教程
Java教程
Jsp教程
开发技术
微信小程序教程
Uniapp开发教程
微信公众号开发
Andriod教程
IOS教程
DOS教程
Python教程
Docker教程
Windows Container教程
数据库
MSSQL教程
MySQL教程
Redis教程
Access教程
Oracle教程
数据库教程
操作系统
Linux教程
Windows教程
MAC教程
Cisco教程
交换机教程
防火墙教程
搜索
爱易网页
JS特效
手动调节背景色
手动调节背景色
日期:2014-05-18 浏览次数:20273 次
欢迎光临爱易网网页脚本特效中心,点击运行按钮演示特效:
以下是程序代码
<html> <head> <title>爱易网网页特效演示,手动调节背景色</title> <style type="text/css"> <!-- body { font-family: "宋体"; font-size: 9pt; margin-top: 0px; margin-left: 4px; margin-right: 0px} A { COLOR: black; FONT-SIZE: 9pt; FONT-WEIGHT: 400; TEXT-DECORATION: none } A:hover { COLOR: red; FONT-SIZE: 9pt; FONT-WEIGHT: 400; TEXT-DECORATION: underline } a:active { font: 9pt "宋体"; cursor: hand; color: #FF0033 } --></style> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> </head> <body> <center><font color=red face="隶书" size=6>手动调节背景色</font></center> <center> <table border=1 bordercolor=#000000 borderlight=green style="border-collapse: collapse" cellpadding="0" cellspacing="0"> <tr><td align=center><font size=5 color=red face="Arial, Helvetica, sans-serif"><strong>下面为脚本显示区</strong></font></td></tr><tr><td align=center><script language="JavaScript"> <!-- Hiding var red=0; var green=0; var blue=0; var value=0; var convert = new Array() var hexbase= new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F"); for (x=0; x<16; x++){ for (y=0; y<16; y++){ convert[value]= hexbase[x] + hexbase[y]; value++; } } function clear(){ document.color.bl.value= blue; document.color.rd.value= red; document.color.gr.value= green; } function display(){ redx = convert[red] greenx = convert[green] bluex = convert[blue] var rgb = "#"+redx+greenx+bluex; document.color.rgbdspl.value= rgb; document.bgColor =rgb; } function upred(x){ if ((red+x)<=255) red+=x document.color.rd.value= red; display() } function downred(x){ if ((red-x)>=0) red-=x document.color.rd.value= red; display() } function upgreen(x){ if ((green+x)<=255) green+=x document.color.gr.value= green; display() } function downgreen(x){ if ((green-x)>=0) green-=x document.color.gr.value= green; display() } function upblue(x){ if ((blue+x)<=255) blue+=x document.color.bl.value= blue; display() } function downblue(x){ if ((blue-x)>=0) blue-=x document.color.bl.value= blue; display() } // done hiding --> </script> <form name="color"> <table> <tr align="Center"> <td> <input name="red" type="button" value=" +50 " onClick="upred(50)"> </td> <td> <input name="red2" type="button" value=" + 10 " onClick="upred(10)"> </td> <td> <input name="red2" type="button" value=" + 1" onClick="upred(1)"> </td> <td width="50"><font color="#FF0000" size=+3><b><font color="#FA0000">红</font></b></font></td> <td> <input name="red-" type="button" value=" - 1" onClick="downred(1)"> </td> <td> <input name="red-" type="button" value=" - 10 " onClick="downred(10)"> </td> <td> <input name="red-" type="button" value=" -50 " onClick="downred(50)"> </td> <td> <input type="text" name="rd" size=3> </td> </tr>
上一篇:狡猾的按钮特效
下一篇:很不错的背景调色板
免责声明:
本文仅代表作者个人观点,与爱易网无关。其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
相关资料
更多>
小米移动芯片:英伟达退出,终会加强与联发科合作
AMD Q1净亏1.46亿美元 转战SOC拥抱ARM求变
【晚报】女子泰国游晒10照片 流量费2000
谷歌董事长成花花公子:情史足以媲美涂鸦
苹果6月20日发布iPhone5S 触摸屏概念股生动
从雷军的“互联网七字诀”告诉你一个非妖魔化的小米
全球最具“颠覆性”特质的公司排行榜TOP25
华为变阵:任正非调整三大业务布局
一大波智能路由器正在袭来:小米、360、极路由大PK
推荐阅读
更多>
小米移动芯片:英伟达退出,终会加强与联发科合作
猎豹移动上市押海外市场 与小米有合作空间
小微型IDC云化趋势加剧 云计算未来或现终极模式
“组合拳”怎么打 拆解小米新玩法
百度透露无人驾驶战略 研发三维交通地图
中移动一季度净利大降:手机补贴增长过快
苹果iWatch或使用量产液态金属 将取代玻璃
京东封杀财付通:终极目标是电商生态圈
完美入股盛大:一桩各怀心事的交易
微软与摩托罗拉授权协议涵盖Android和Chrome设备
看蜗牛如何放水养鱼,盘活生态系统
欧洲6万人起诉Facebook隐私侵权
【晚报】女子泰国游晒10照片 流量费2000
据消息传百度将要控股携程 整合去哪儿
打车软件火了 恶性循环来了
解读苹果收购Beats背后动机:库克在想什么?
网曝富士康500万iphone遭退货是确证的事
公信力消失:马航事件社交媒体传播之痛
苹果售后生态链乱象:供需失衡价钱不一
迪信通神秘免费服务揭谜底:充电宝免费带回家