多くの onclick 機能を実装しました。しかし、ここだけで機能しているわけではありません。
私のHTML
<body style="background-color:#333333;">
<div id="wrapper_other" class="wrapper_other">
<div id="header" class="header">
<div id="header_title" class="header_title"></div>
<div id="home" class="home"><img src="img/home.png" onClick="home()"/></div>
</div>
私のCSS
.wrapper_other
{
width:auto; margin:0auto; overflow: hidden;
}
.header
{
float:left; height:44px; line-height:44px; margin:0%; width:100%;
}
.header_title
{
height:100%; min-height:100%; font-size:22px; color: #FFFFFF; text-align:center; font-weight:bold; width:100%;
}
私の機能
function home()
{
window.location.href="index.html";
}
編集
私のファイル構造
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" charset="utf-8">
function test()
{
window.location.href="index.html";
}
</script>
</head>
<body style="background-color:#333333;">
<div id="wrapper_other" class="wrapper_other">
<div id="header" class="header">
<div id="header_title" class="header_title"></div>
<div id="home" class="home"><img src="img/home.png" onClick="info()"/> </div>
</div>
<div id="images" class="images"><img name="slide" src="img/banner1.png" width=100% />
<div id="element_name_image" class="element_name_image"></div>
</div>
<div id="parameters" style="background-image:url(img/icons_bg.png);" class="parameters">
<div id="abc" class="abc"></div>
<div id="def" class="def"></div>
<div id="ghi" class="ghi"></div>
<div id="jkl" class="jkl"></div>
</div>
<div id="wrapper" class="wrapper">
<div id="scroller" class="scroller">
<ul>
<div id="description" class="description">
<div id="title" class="title">
<h1><strong><ul class="scroller ul"><li></li></ul></strong></h1>
</div>
<div id="desc" class="desc">
<p><ulclass="scroller ul"><li></li></ul></p>
</div>
</div>
</ul>
</div>
</div>
私の間違いを特定するのを手伝ってください。