好吧,所以我有一個登錄按鈕在我的網站的頂部,當點擊calles一些jquery顯示/隱藏登錄框。jquery幫助切換
但我有一個搜索框旁邊,當你點擊,不僅無法輸入它,但它也切換日誌在框中的第一個代碼應該是jquery和secong是html部分這叫它。順便說一句,它的jQuery 1.4.2。如果你想看到它,你可以訪問http://www.stat-me.com並點擊登錄,並嘗試單擊搜索博
謝謝。
JQUERY:
<script src="js/jquery/jquery-1.4.2.js" type="text/javascript"></script>
<script language="javascript" type="text/javascript">
// run the function below once the DOM(Document Object Model) is ready
$(document).ready(function() {
// trigger the function when clicking on an assigned element
$(".toggle").click(function() {
// check the visibility of the next element in the DOM
if ($(this).next().is(":hidden")) {
$(this).next().slideDown(); // slide it down
} else {
$(this).next().slideUp("fastS"); // hide it
}
});
$(".exito").click(function() {
// check the visibility of the next element in the DOM
if ($(this).next().is(":hidden")) {
$(this).next().show(); // slide it down
} else {
$(this).next().hide(); // hide it
}
});
});
</script>
HTML:
<span class="toggle" style="margin-top:-583px; margin-left:950px; position:relative;">
<a href="#">LOG IN</a>
</span>
<div class="secondehiddendiv">
<div class="chat-bubble">
<h1 style="color:#F00">LOG IN!</h1>
<form name="login" method="post" action="login.php">
<table style="margin-left:-5px; text-align:right; color:#F00;">
<tr>
<td>Email:</td>
<td><input name="email" type="text" size="17" ></td>
</tr>
<tr>
<td>Password:</td>
<td><input name="password" type="password" size="17" ></td>
</tr>
</table>
<div class="log_in_img">
<input type="image" src="http://www.stat-me.com/images/log_in_jq.png" alt="LOG IN" >
</div>
</form>
<div class="chat-bubble-arrow-border"></div>
<div class="chat-bubble-arrow"></div>
</div>
</div>
讓我怎麼停止(IM還挺新) – DonJuma 2010-07-07 15:01:01
沒關係我得到它我只是說50分像素的感謝的寬度很多 – DonJuma 2010-07-07 15:06:10
在帕特里克建議的搜索框中添加您的登錄鏈接。我用一個例子編輯了我的答案。 – stormdrain 2010-07-07 15:10:27