Home > Web Front-end > JS Tutorial > body text

Change img images through onmouseover tab_javascript skills

WBOY
Release: 2016-05-16 17:00:24
Original
1450 people have browsed it
复制代码 代码如下:





选项卡实现img图片的变换














<script> <br>function show(n){ <br>for(var i=1;i<=4;i ){ <BR>document.getElementById("tab" i).style.backgroundColor='green'; <BR>document.getElementById("p" i).style.display='none'; <BR>//display实现内容的隐藏与否的控制,当为none是,隐藏 <BR>} <BR>document.getElementById("tab" n).style.backgroundColor='white'; <BR>document.getElementById("p" n).style.display='block'; <BR>//当block时,隐藏的即可显示 <BR>} <BR></script>

Related labels:
Tab
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!