Ma`lumotlar : 1092
Xabarlar soni: 591
Bugun: 16.11.2026
Soat: 22:55
Qidiruv oynasini yaratish uchun HTML oynasidan foydalanish
Muallif: Mengliyev SH.
Qo`shilgan sana: 2014-07-06
Qidiruv oynasini yaratish uchun HTML oynasidan foydalshingiz mumkin
Ishlatiladigan qidiruv sestemada iframe saytini boshqa tarqatib bo’lmaydi. Hozigi vaqtda ishlatiladigan format qidiruv elimenti ishlatiladi, lekin HTML formasini ko’rsatib o’zingiz sayttingizga qo’shib yozing:
<form id="cse-search-box" action="http://google.com/cse">
<input type="hidden" name="cx" value="здесь указывается ID вашей поисковой системы" />
<input type="hidden" name="ie" value="UTF-8" />
<input type="text" name="q" size="31" />
<input type="submit" name="sa" value="Search" />
</form>
<img src="http://www.google.com/cse/images/google_custom_search_smwide.gif">
Ko’rsatilagan kata primer tekis joyda ID kodingizni ko’rsating. Uni bilish uchun “Настройка”ga kirasiz “ Идентификатор поисковой системы” shuning ichida “Основные сведения”ni bosasiz.
“ JavaScript”ni o’chirish
Bu elimintda ishlash uchun brovzerdagi JavaScript o’chirilgan bo’lsa saytga yangi oyna yarating HTML yordamida va nojs parametirini ko'rsating.
<form id="cse-search-box" action="http://google.com/cse">
<input type="hidden" name="cx" value="ИДЕНТИФИКАТОР ПОИСКОВОЙ СИСТЕМЫ" />
<input type="hidden" name="ie" value="UTF-8" />
<input type="text" name="q" size="31" />
<input type="submit" name="sa" value="Search" />
<input type="hidden" name="nojs" value="1" />
</form>
<img src="http://www.google.com/cse/images/
google_custom_search_smwide.gif">
Sayt uchun oddiy izlash
Bu izlashning oddiy ko’rinishi xichqanday qiyinchiliklarsiz amalga oshadi. Buni sayt uchun oddiy izlash deb tushunsa bo’ladi
<form method="get" action="">
<input
onblur="this.value=(this.value=='')?this.title:this.value;this.style.backgroundColor='#ccc';"
onfocus="this.value=(this.value==this.title)?'':this.value;this.style.backgroundColor='#fff';"
value="Поиск"
title="Поиск"
type="text"
style="text-align: center; background-color: #ccc;" />
<input class="search-btn" type="submit" value="ok" />
</form>
Rangli izlash formasi
Bu izlash formasi foni kulrang bo’lib izlash uchun ma’lum so’z yozgangandan so’ng kulrang yo’qoladi. Oddiy lekin chiroyli izlash formasi. Bu izlash formasida suratlar qo’llaniladi. Siz o’zingiz xohlagan rasmni qo’ysangiz bo’ladi.
<formmethod="get" action="">
<input name="nomer2" value="" size="20" type="text" style="
color: rgb(255, 255, 255);
border: 2px solid rgb(100, 117, 134);
padding: 5px 2px 5px 30px;
background: url(1.png) no-repeat scroll 5% 50% rgb(68, 85, 102);
">
</form>
background: url(1.png) no-repeatscroll 5% 50% rgb(68, 85, 102);
Izlashning cho’ziluvchan formasi
Nima uchun cho’ziluvchan forma ? Nimaga deganda formga bosganigizda so’z kiritish maydoni so’zning uzunligiga qarab cho’zilib ketaveradi.
<html>
<head>
<style>
.form-search {
display: inline-block;
background: -moz-linear-gradient(#D3D3D3, #CACACA 50%, #A9A9A9 50%, #9B9B9B);
background: -ms-linear-gradient(#D3D3D3, #CACACA 50%, #A9A9A9 50%, #9B9B9B);
background: -o-linear-gradient(#D3D3D3, #CACACA 50%, #A9A9A9 50%, #9B9B9B);
background: -webkit-linear-gradient(#D3D3D3, #CACACA 50%, #A9A9A9 50%, #9B9B9B);
border-radius: 5px;
padding: 4px;
}
.form-search input {
width: 75px;
height: 32px;
line-height: 32px;
font: 13px Helvetica, Arial, sans-serif;
color:#6E7074;
text-shadow: 0 1px 0 #FFF;
-moz-transition: all .2s ease-out;
-webkit-transition: all .2s ease-out;
-o-transition: all .2s ease-out;
transition: all .2s ease-out;
padding: 0 30px 0 6px;
background-image: url("search.png"), -moz-linear-gradient(#BCBCBC, #EBEBEB);
background-image: url("search.png"), -ms-linear-gradient(#BCBCBC, #EBEBEB);
background-image: url("search.png"), -o-linear-gradient(#BCBCBC, #EBEBEB);
background-image: url("search.png"), -webkit-linear-gradient(#BCBCBC, #EBEBEB);
background-repeat: no-repeat;
background-position: 100% 50%, 100% 100%;
border: 1px solid #747474;
border-radius: 3px;
box-shadow: inset 0 1px 1px #575555, 0 1px 0 #FFF;
}
.form-search input:focus {
width: 160px;
box-shadow: inset 0 1px 1px #46575b, 0 1px 0 #FFF;
color: #25464D;
background-image: url("search.png"), -moz-linear-gradient(#9CC2CA, #DFECEF);
background-image: url("search.png"), -ms-linear-gradient(#9CC2CA, #DFECEF);
background-image: url("search.png"), -o-linear-gradient(#9CC2CA, #DFECEF);
background-image: url("search.png"), -webkit-linear-gradient(#9CC2CA, #DFECEF);
}
</style>
</head>
<body>
<form class="form-search" method="get" action="/search" target="_blank">
<input type="text" name="q" placeholder="поиск" value=""/>
</form>
</body>
</html>
Izlash farmasi html uchun
<html>
<head>
<style>
.searchform {
display: inline-block;
zoom: 1;
*display: inline;
border: solid 1px #d2d2d2;
padding: 3px 5px;
-webkit-border-radius: 2em;
-moz-border-radius: 2em;
border-radius: 2em;
-webkit-box-shadow: 0 1px 0px rgba(0,0,0,.1);
-moz-box-shadow: 0 1px 0px rgba(0,0,0,.1);
box-shadow: 0 1px 0px rgba(0,0,0,.1);
background: #f1f1f1;
background: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#ededed));
background: -moz-linear-gradient(top, #fff, #ededed);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#ededed'); /* ie7 */
-ms-filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#ededed'); /* ie8 */
}
.searchform input {
font: normal 12px/100% Arial, Helvetica, sans-serif;
}
.searchform .searchfield {
background: #fff;
padding: 6px 6px 6px 8px;
width: 202px;
border: solid 1px #bcbbbb;
outline: none;
-webkit-border-radius: 2em;
-moz-border-radius: 2em;
border-radius: 2em;
-moz-box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
}
.searchform .searchbutton {
color: #fff;
border: solid 1px #494949;
font-size: 11px;
height: 27px;
width: 27px;
text-shadow: 0 1px 1px rgba(0,0,0,.6);
-webkit-border-radius: 2em;
-moz-border-radius: 2em;
border-radius: 2em;
background: #5f5f5f;
background: -webkit-gradient(linear, left top, left bottom, from(#9e9e9e), to(#454545));
background: -moz-linear-gradient(top, #9e9e9e, #454545);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#9e9e9e', endColorstr='#454545'); /* ie7 */
-ms-filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#9e9e9e', endColorstr='#454545'); /* ie8 */
}
</style>
</head>
<body>
<form class="searchform">
<input class="searchfield" type="text" value="Поиск..." onfocus="if (this.value == 'Поиск...') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Поиск...';}" />
<input class="searchbutton" type="button" value="Да" />
</form>
</body>
</html>
3397 marta o`qildi.