Home >Web Front-end >JS Tutorial >js click to change the background color or image example code_javascript skills

js click to change the background color or image example code_javascript skills

WBOY
WBOYOriginal
2016-05-16 17:31:211256browse

1, button style

Copy code The code is as follows:

<script><br>org_Color=document.bgColor.substring(1.10)<br></script>









2, drop-down style
Copy code The code is as follows:


3, touch style
Copy code The code is as follows:

< ;scriptlanguage="Javascript">



Touch me to change the background color

Click to change the background image:

Copy the code The code is as follows:









IE6不能用的解决方法:

复制代码 代码如下:


Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn