43 users online (1 members and 42 guests)  


  Results 1 to 14 of 14

Related

  1. Java scripts object material    Forum: Javascript Forum
    Replies: 1
  2. java scroll bar script?    Forum: Website Scripts Forum
    Replies: 1
  3. Java email script & W3C.org    Forum: Javascript Forum
    Replies: 5
  4. Another Java-Script Question    Forum: Javascript Forum
    Replies: 4
  1. #1
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Exclamation Other scripts Dhtml / java script

    if you like to add something cool to your web site to have fun try this one


    Enter it in the <body> tag were you want it to show up at

    <h2>
    <script language="JavaScript1.2">


    var message="PUT WHAT YOU WANT HERE"
    var neonbasecolor="gray"
    var neontextcolor="yellow"
    var flashspeed=100 //in milliseconds

    ///No need to edit below this line/////

    var n=0
    if (document.all||document.getElementById){
    document.write('<font color="'+neonbasecolor+'">')
    for (m=0;m<message.length;m++)
    document.write('<span id="neonlight'+m+'">'+message.charAt(m)+'</span>')
    document.write('</font>')
    }
    else
    document.write(message)

    function crossref(number){
    var crossobj=document.all? eval("document.all.neonlight"+number) : document.getElementById("neonlight"+number)
    return crossobj
    }

    function neon(){

    //Change all letters to base color
    if (n==0){
    for (m=0;m<message.length;m++)
    //eval("document.all.neonlight"+m).style.color=neonbasecolor
    crossref(m).style.color=neonbasecolor
    }

    //cycle through and change individual letters to neon color
    crossref(n).style.color=neontextcolor

    if (n<message.length-1)
    n++
    else{
    n=0
    clearInterval(flashing)
    setTimeout("beginneon()",1500)
    return
    }
    }

    function beginneon(){
    if (document.all||document.getElementById)
    flashing=setInterval("neon()",flashspeed)
    }
    beginneon()


    </script>
    </h2>


    this one goes through it all with yellow with a gray background



    edit: spelling
    Last edited by HTML; 05-29-2002 at 06:19 PM.

  2. #2
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Lightbulb another one like the top but cooler

    this one scrolles through the letters



    <h2><script language="JavaScript1.2">

    //Neon Lights Text II


    var message="Put what you like to say here "
    var neonbasecolor="gray"
    var neontextcolor="yellow"
    var neontextcolor2="#FFFFA8"
    var flashspeed=100 // speed of flashing in milliseconds
    var flashingletters=3 // number of letters flashing in neontextcolor
    var flashingletters2=1 // number of letters flashing in neontextcolor2 (0 to disable)
    var flashpause=0 // the pause between flash-cycles in milliseconds

    ///No need to edit below this line/////

    var n=0
    if (document.all||document.getElementById){
    document.write('<font color="'+neonbasecolor+'">')
    for (m=0;m<message.length;m++)
    document.write('<span id="neonlight'+m+'">'+message.charAt(m)+'</span>')
    document.write('</font>')
    }
    else
    document.write(message)

    function crossref(number){
    var crossobj=document.all? eval("document.all.neonlight"+number) : document.getElementById("neonlight"+number)
    return crossobj
    }

    function neon(){

    //Change all letters to base color
    if (n==0){
    for (m=0;m<message.length;m++)
    crossref(m).style.color=neonbasecolor
    }

    //cycle through and change individual letters to neon color
    crossref(n).style.color=neontextcolor

    if (n>flashingletters-1) crossref(n-flashingletters).style.color=neontextcolor2
    if (n>(flashingletters+flashingletters2)-1) crossref(n-flashingletters-flashingletters2).style.color=neonbasecolor


    if (n<message.length-1)
    n++
    else{
    n=0
    clearInterval(flashing)
    setTimeout("beginneon()",flashpause)
    return
    }
    }

    function beginneon(){
    if (document.all||document.getElementById)
    flashing=setInterval("neon()",flashspeed)
    }
    beginneon()


    </script></h2>


  3. #3
    benzden's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Feb 2002
    Location
    San Antonio, Texas
    Posts
    652
    See it at the bottom of

    http://test.gumint.com

    in a table.

  4. #4
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Yes

    Thats good what did you do with marquee to do that it took me for ever to do that in java scrpit lmao

  5. #5
    benzden's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Feb 2002
    Location
    San Antonio, Texas
    Posts
    652
    That's your Javascript code placed in a TABLE with different colors, wording and sizes!

  6. #6
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    O

    O, i couldn't view all of your source code because my pc doesn't support frames lol

  7. #7
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Should i Post more codes like that?

    Should i start posting more codes like that?

  8. #8
    benzden's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Feb 2002
    Location
    San Antonio, Texas
    Posts
    652
    Using IE 5.01+, view the pages properties to see the URL to the real location on the host server. Go there to view the page source.

    It's at:

    http://jamrent.50megs.com/ben/test.htm




    Of course you should upload more! Or upload an HTML page that contains just the code in an example you're designing it for.

    We all like things like that - both the functional and not-so-readily-apparent-functional.

  9. #9
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Unhappy Ok I will

    I will upload and make a page to show the work etc...
    But, facts show that i have a very small archive of codes that i've done or that friends of mine have done etc...
    or even ones that i know by heart

  10. #10
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Also

    Also i would like to know how you made the button to go to certain parts of the page if thats ok
    It seemd they would work better for a site like mine since i have alot of stuff and different subdomaines etc...

  11. #11
    benzden's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Feb 2002
    Location
    San Antonio, Texas
    Posts
    652
    If you're talking about the back and bottom URLS, go ahead and use what's there. Nobody can copyright .gif images so far as I'm aware - one of the reasons Compuserve kept the copyright was to keep someone else from restricting it.

    If using that double down bottom, which is really two images surrounding "bottom" in an anchor tag, I'd suggest converting it to one image and using that. I'll do so eventually. It only started out as a much dumber down arrow, then two made more sense.

    If you're talking about other buttons, let me know which ones specifically - there are so many. And, once you see the source code, you should be able to take what you want, including saving any images.

    I'm really graphically challenged but am learning some really basic tricks regarding really basic images. Most of them can be discovered by analyzing the images themselves inside MSpaint - which is where they were created.

  12. #12
    creature's Avatar
    New User

    Status
    Offline
    Join Date
    May 2002
    Posts
    22

    Unhappy Somewhat

    I was talking about the action they do such as Pressing top goes to the top etc... what was the code for that?

  13. #13
    Enigma's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Nov 2000
    Posts
    426
    http://htmlgoodies.earthweb.com/tutors/pagejump.html

  14. #14
    benzden's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Feb 2002
    Location
    San Antonio, Texas
    Posts
    652
    <A NAME=top> </A>

    (... web page text, images, tables, etc. ...)

    <A HREF=#top>go to top of page</A>



    The #top goes hand in hand with the NAME=top
    in those anchor tag pairs.

    This is how one can direct someone to a specific portion of a web site, like I do all the time at dozens of pages. For example,

    http://jamrent.50megs.com/ben/test.htm#middle

    should bring the visitor directlly to whatever coding follows the <A NAME=middle>& #160 ;</A> tag on that page.

    Note that I always place the chr #160 [ remove the spaces after the & and before the ; ] in all the NAME= tags except for the NAME=top at the top of the page. That techinque gets around some bugs in some browsers. Chr #160 is a blank space unlike the chr #32 blank space.
    Last edited by benzden; 05-15-2002 at 10:51 PM.



Tags for this Thread