Pages

Minggu, 27 Januari 2013

Cara membuat Search Engine Di Blog

Diposting oleh Mauli di 03.10
Dengan kamu memasang Search Engine Di Blog kamu, pengunjung akan lebih mudah menemukan artikel yang dicari dengan demikian akan meningkatkan jumlah Page View blog kamu.

Langkah-Langkah :

1. Login ke Dashbord blog kamu
2. Jika sudah, kamu pilih Tata Letak
3. Jika sudah Klik Add a Gadget atau Tambah Gadget
4. Pilih Widget HTML/JavaScript
5. Copas Kode berikut ini, dan masukan kedalam kolom Widget HTML/JavaScript


<form name="jksearch" action="http://www.google.com/search" method="get" onsubmit="jksitesearch(this)" target="_blank">
<input id="hiddenquery" type="hidden" name="q" />
<input name="qfront" onfocus="if(this.value==this.defaultValue)this.value='';" value="Search on this site..." type="text" onblur="if(this.value=='')this.value=this.defaultValue;" style="width: 240px;border:none;padding:8px 10px; font:normal 11px arial;color:#666; background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4nhVuSwt7lCsZs_wK6jf4w8jvTDzgVkZKbAFMknFrJ6F02vGvlYCEYif2ybP2Sv2mN08xF6TCcsKSmkQoT98MvXZK4o89GqQjT-Zh-F_u6YhgAi0OevEZ590E4rb4kH_dbcckjlGkct8/s1600/search_field.jpg) no-repeat;" /><input type="image" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgdStcjKtWq4515_s01yciPOw-eGZ5ys9u5UgvKzQT-ABPB0zu8aewmFrLJQu3dPN9xlDIrHN5mwo2KKqZ1NZ1jj5xQmRYKbKovcglo2pHOAFHxMy-RXswnTXMi-lxMheeIthDaaznPuPA/s1600/search_button.jpg" align="top" value="Search"/>
<div style="font: normal 11px Arial;color:#666;padding:2px 0;">
<input name="se" type="radio" checked /> Google
<input name="se" type="radio" /> Yahoo
<input name="se" type="radio" /> Msn
</div>
<script type="text/javascript">
// All-in-one Internal Site Search script- By JavaScriptKit.com (http://www.javascriptkit.com)
// For this and over 400+ free scripts, visit JavaScript Kit- http://www.javascriptkit.com/
// This notice must stay intact for use
//Enter domain of site to search.
var domainroot="http://blogmashanif.blogspot.com/"
var searchaction=[ //form action for the 3 search engines
"http://www.google.com/search",
"http://search.yahoo.com/search",
"http://search.msn.com/results.aspx"
]
var queryfieldname=["q","p","q"] //name of hidden query form for the 3 search engines
function switchaction(cur, index){
cur.form.action=searchaction[index]
document.getElementById("hiddenquery").name=queryfieldname[index]
}
function jksitesearch(curobj){
for (i=0; i< document.jksearch.se.length; i++){ //loop through radio to see which is checked
if (document.jksearch.se[i].checked==true)
switchaction(document.jksearch.se[i], i)
}
document.getElementById("hiddenquery").value="site:"+domainroot+" "+curobj.qfront.value
}
</script>
</form>

5. Ganti kode yang berwarna Merah dengan Url Blog kamu
6. Sekarang Klik Simpan
7. Selesai dan Lihat Hasilnya
Semoga bermanfaat :D

0 komentar:

 

Mauli's Blog Template by Ipietoon Blogger Template | Gift Idea