java komutlarii

Son güncelleme: 26.11.2005 01:08
  • burda bazi java komutlarini sunmak istiyorum


    Button seklinde saat

    <SCRIPT LANGUAGE="JavaScript">




    <!-- Begin
    day = new Date();
    miVisit = day.getTime();
    function clock() {
    dayTwo = new Date();
    hrNow = dayTwo.getHours();
    mnNow = dayTwo.getMinutes();
    scNow = dayTwo.getSeconds();
    miNow = dayTwo.getTime();
    if (hrNow == 0) {
    hour = 12;
    ap = " AM";
    } else if(hrNow <= 11) {
    ap = " AM";
    hour = hrNow;
    } else if(hrNow == 12) {
    ap = " PM";
    hour = 12;
    } else if (hrNow >= 13) {
    hour = (hrNow - 12);
    ap = " PM";
    }
    if (hrNow >= 13) {
    hour = hrNow - 12;
    }
    if (mnNow <= 9) {
    min = "0" + mnNow;
    }
    else (min = mnNow)
    if (scNow <= 9) {
    secs = "0" + scNow;
    } else {
    secs = scNow;
    }
    time = hour + ":" + min + ":" + secs + ap;
    document.form.button.value = time;
    self.status = time;
    setTimeout('clock()', 1000);
    }
    function timeInfo() {
    milliSince = miNow;
    milliNow = miNow - miVisit;
    secsVisit = Math.round(milliNow / 1000);
    minsVisit = Math.round((milliNow / 1000) / 60);
    alert("There have been " + milliSince + " milliseconds since midnight, January 1, 1970. "
    + "You have spent " + milliNow + " of those milliseconds on this page. "
    + ".... About " + minsVisit + " minutes, and "
    + secsVisit + " seconds.");
    }
    document.write("<form name=\"form\">"
    + "<input type=button value=\"Click for info!\""
    + " name=button onClick=\"timeInfo()\"></form>");
    onError = null;
    clock();
    // End -->
    </SCRIPT>



    Norml saat

    <script language="JavaScript">
    <!--


    function show(){
    if (!document.layers&&!document.all)
    return
    var Digital=new Date()
    var hours=Digital.getHours()
    var minutes=Digital.getMinutes()
    var seconds=Digital.getSeconds()
    var dn="AM"
    if (hours>12){
    dn="PM"
    hours=hours-12
    }
    if (hours==0)
    hours=12
    if (minutes<=9)
    minutes="0"+minutes
    if (seconds<=9)
    seconds="0"+seconds

    //change font size here to your desire

    myclock="<font size='5' face='Arial' color='blue'><b><font size='2'>Current date and time:</font></br>"+hours+":"+minutes+":"
    +seconds+" "+dn+"</b></font>"
    if (document.layers){
    document.layers.liveclock.document.write(myclock)
    document.layers.liveclock.document.close()
    }
    else if (document.all)
    liveclock.innerHTML=myclock
    setTimeout("show()",1000)
    }
    //-->
    </script></HEAD><BODY><span id="liveclock" style="position:absolute;left:1;top:1;">
    </span>

    <SCRIPT LANGUAGE="JavaScript">
    <!--
    setTimeout('show()',10);
    //-->
    </SCRIPT>


    devami yarina artikk
#22.11.2005 23:28 0 0 0
  • sagol dostum deneyelım bakalım
#25.11.2005 16:24 0 0 0
  • devami yarin dedik birza gec oldu ama buyrun devami

    büyüyüp kücülen yazi


    <script language="Javascript1.2">
    <!--


    var tags_before_clock = "<center>";
    var tags_after_clock = "</center>";

    var speed = 100;
    var speed2 = 2000;
    var biggest_text = 28;

    var x = 0;
    var y = 0;
    var themessage, size;
    var esize = "</font>";

    function initArray() {

    this.length = initArray.arguments.length;
    for (var i = 0; i < this.length; i++) {
    this = initArray.arguments;
    }
    }

    var themessage2 = new initArray(
    "This is the Growing Banner.",
    "It looks a lot cooler than other banners.",
    "This is really easy to conform to your page.",
    "Just don't make it too long or else..."
    );

    if(navigator.appName == "Netscape") {
    document.write('<layer id="wds"></layer><br>');
    }

    if (navigator.appVersion.indexOf("MSIE") != -1){
    document.write('<span id="wds"></span><br>');
    }

    function upwords(){

    themessage = themessage2[y];

    if (x < biggest_text) {
    x++;
    setTimeout("upwords()",speed);
    }

    else {
    setTimeout("downwords()",speed2);
    }

    if(navigator.appName == "Netscape") {
    size = "<font point-size='"+x+"pt'>";
    document.wds.document.write(size+tags_before_clock+themessage
    +tags_after_clock+esize);
    document.wds.document.close();
    }

    if (navigator.appVersion.indexOf("MSIE") != -1){
    wds.innerHTML = tags_before_clock+themessage+tags_after_clock;
    wds.style.fontSize=x+'px'
    }
    }

    function downwords(){

    if (x > 1) {
    x--;
    setTimeout("downwords()",speed);
    }

    else {
    setTimeout("upwords()",speed2);
    y++;
    if (y > themessage2.length - 1) y = 0;
    }

    if(navigator.appName == "Netscape") {
    size = "<font point-size='"+x+"pt'>";
    document.wds.document.write(size+tags_before_clock+themessage
    +tags_after_clock+esize);
    document.wds.document.close();
    }

    if (navigator.appVersion.indexOf("MSIE") != -1){
    wds.innerHTML = tags_before_clock+themessage+tags_after_clock;
    wds.style.fontSize=x+'px'
    }
    }

    setTimeout("upwords()",speed);
    //-->
    </script>






    dialog kutusu



    <FORM>
    <INPUT TYPE="button" VALUE="Click Here to See It"
    onClick='alert("This is what you get")'>
    <FORM>



    hesap makinesi



    <SCRIPT LANGUAGE="JAVASCRIPT">
    <!--

    function Oblicz(Objec) {
    Objec.domesum.value = eval(Objec.expr.value)
    }

    //-->

    </SCRIPT>
    </HEAD>

    <BODY>

    <form name="Calculator">
    <pre>
    Sum:
    <BR><input type="text" name="expr" size="20">
    End Product:
    <input type="text" name="domesum" size="20">
    <input type="button" name="B1"
    value=" Calculate "
    onClick="Oblicz(this.form)"
    </pre>
    </form>
#26.11.2005 01:08 0 0 0