您的位置:首页 > 其它

两种搜索模式更换

2016-07-28 13:53 393 查看
<form action="javascript:search_brand()" name="searchForm">
<img src="<?php echo base_url('Public/images/icon_search.gif')?>" width="26" height="22" border="0" alt="SEARCH">
<input type="text" name="ss" placeholder="请输入搜索关键字" id="ss" size="15">
<input type="text" name="ss" style="display: none" id="sss" class="ss" size="15"/>
<input type="button" value="搜索" style="display: none" class="sou">
<b id="bi" style="display: none;color: red;cursor: pointer">换种方式搜索</b>
<b id="zhan" style="color: red;cursor: pointer">换种方式搜索</b>
</form>
<script>
$(document).on('click','#zhan',function(){
//点击换种方式搜索
$('#zhan').hide('hide');//展示隐藏
$('#ss').hide('hide');//文本框隐藏
$('#sss').show('slow')//换一个文本框展示
$('.sou').show('slow');//搜索按钮展示
$('#bi').show('slow');//换一个字段提示
})
$(document).on('click','#bi',function(){
$('.sou').hide('hide');
$('#bi').hide('hide');
$('#zhan').show('slow');
$('#ss').show('slow');
$('#sss').hide('hide')
})
</script>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: