Programalama > JAVA SCRIPT

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
<script>
function Keybul() 
{
var yazmaca=document.all.yz;
var uzunluk=document.frm.a.options.length;
var secme=document.frm.a;
		if (event.keyCode == 13){  
		yazmaca.innerText="Entere Bastın\n";
		}else{
		var d=document.frm.tmp.value;
			if (event.keyCode==32){
			eski="";
			document.frm.tmp.value=eski;
			document.frm.a.options[0].selected = true;
			}else{
		var eski=d+String.fromCharCode(event.keyCode);
		var eski=eski.toLowerCase();
		document.frm.tmp.value=eski;
		var gelen_uzunluk=eski.length;
		
			for (i=1;i<uzunluk;i++){
			al=secme.options[i].text.toLowerCase();
			al_bol=al.substring(0,gelen_uzunluk);
			if (al_bol==eski){
			document.frm.a.options[i].selected = true;
			}
	} // for sonu
		}

		} //boşluk sonu
}
document.onkeypress = Keybul;
</script>
</HEAD>
<BODY>
<FORM METHOD=POST ACTION="" name="frm">
<input type="hidden" name="tmp">
<SELECT NAME="a" onkeyup="Keybul()">
<option value="-------"></option>
<option value="1">Ahmet</option>
<option value="2">tuncay</option>
<option value="3">turgay</option>
<option value="4">ali</option>
<option value="5">mehmet</option>
<option value="6">memo</option>
<option value="7">abdurrahman</option>
<option value="8">abuzer</option>
<option value="9">fatih</option>
<option value="10">mezire</option>
<option value="11">zahit</option>
<option value="12">emre</option>
<option value="13">selami</option>
</SELECT><br>
<div id=yz></div><br>
</FORM>
</BODY>
</HTML>


Yorumlar                 Yorum Yaz
Bu hazır kod'a ilk yorumu siz yapın!
KATEGORİLER
ASP - 240
ASP.NET - 24
C# - 75
C++ - 174
CGI - 8
DELPHI - 247
FLASH - 49
HTML - 536
PASCAL - 246
PERL - 11
PHP - 160
WML - 9
XML - 2
Copyright © 2002 - 2024 Hazır Kod - Tüm Hakları Saklıdır.
Siteden yararlanırken gizlilik ilkelerini okumanızı tavsiye ederiz.
hazirkod.com bir İSOBİL projesidir.