首页上一页 1 下一页尾页 1 条记录 1/1页
php oa办公系统主页面的样式和js问题
发表在PHP图书答疑
2016-02-24
是否精华
是
否
版块置顶:
是
否
相关代码:
left.php:
<script src="js/client_js.js"></script>
<script language=JavaScript>
document.onclick = clickHandler;
</script>
....
client_js.js:
function clickHandler() {
var targetId, srcElement, targetElement;
srcElement = window.event.srcElement;
if (srcElement.className == "Outline") {
targetId = srcElement.id + "details";
imgid = srcElement.id + "img";
targetElement = document.all(targetId);
if (targetElement.style.display == "none") {
document[imgid].src = "images/jian.gif";
targetElement.style.display = "";
} else {
document[imgid].src = "images/jia.gif";
targetElement.style.display = "none";
}
}
}
left.php:
<script src="js/client_js.js"></script>
<script language=JavaScript>
document.onclick = clickHandler;
</script>
....
client_js.js:
function clickHandler() {
var targetId, srcElement, targetElement;
srcElement = window.event.srcElement;
if (srcElement.className == "Outline") {
targetId = srcElement.id + "details";
imgid = srcElement.id + "img";
targetElement = document.all(targetId);
if (targetElement.style.display == "none") {
document[imgid].src = "images/jian.gif";
targetElement.style.display = "";
} else {
document[imgid].src = "images/jia.gif";
targetElement.style.display = "none";
}
}
}