Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: Continous marquee

  1. #1
    Join Date
    Sep 2006
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Continous marquee

    Hi guys again, sorry i guess my last thread was a little confusing...
    do any of you know if there is a way to make a marquee continous, basically instead of when the string ends having to have a huge gap and then the string showing again, i would like the string to just keep going. When the last character of the string ends i would like the string to start again instantly, without any white spaces inbetween, is this possible in HTML?

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    29,133
    Thanks
    44
    Thanked 3,229 Times in 3,190 Posts
    Blog Entries
    12

    Default

    No. But, it can be done with javascript:

    http://home.comcast.net/~jscheuer1/side/marqueeh.htm

    or for a vertical version:

    http://home.comcast.net/~jscheuer1/side/marquee.htm

    These both are more cross browser friendly than the marquee tag which has only very limited support in browsers other than IE. A marquee tag (or really a better choice - static content) can be written inside a <noscript></noscript> tag to provide alternate content for javascript impaired browsers.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Sep 2006
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Smile ok...

    ok, thanks a lot i will try javascript. My only concern is that, well i can use vbasic, qbasic, C++, and im kinda starting HTML now and Java, im not really familiar with any of them, and especially not java script, i've never used it in a html based website before.. could you maybe point me to a good java script tutorial plz? anyways thanks for your reply.

  4. #4
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    29,133
    Thanks
    44
    Thanked 3,229 Times in 3,190 Posts
    Blog Entries
    12

    Default

    If you look at the source code, you will see that the configuration of these scripts is well documented as is the demarcation line where you should not cross in editing them. Even though they look long and involved, you just put them wherever you want them in your code, like they were a paragraph (<p></p>).

    There are many online javascript tutorials. Javascript is all one word by the way. Here is a fairly good tutorial:

    http://www.w3schools.com/js/default.asp

    But, I wish they would get rid of that coffee cup image. Javascript is quite different from the Java programming language for which the coffee cup is an early logo, although the code is a little similar.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  5. #5
    Join Date
    Oct 2008
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hello!

    Is it possible to make this script to make a marquee continous? Any help will be very appreciate. Thank you very much!


    <style type="text/css">

    #marqueecontainer{
    position: relative;
    width: 167px; /*marquee width */
    height: 276px; /*marquee height */
    background-color: white;
    overflow: hidden;
    border: 1px solid black;
    padding: 2px;
    padding-left: 4px;
    }

    </style>

    <script type="text/javascript">

    /***********************************************
    * Cross browser Marquee II- c Dynamic Drive (www.dynamicdrive.com)
    * This notice MUST stay intact for legal use
    * Visit http://www.dynamicdrive.com/ for this script and 100s more.
    ***********************************************/

    var delayb4scroll=2000 //Specify initial delay before marquee starts to scroll on page (2000=2 seconds)
    var marqueespeed=1 //Specify marquee scroll speed (larger is faster 1-10)
    var pauseit=1 //Pause marquee onMousever (0=no. 1=yes)?

    ////NO NEED TO EDIT BELOW THIS LINE////////////

    var copyspeed=marqueespeed
    var pausespeed=(pauseit==0)? copyspeed: 0
    var actualheight=''

    function scrollmarquee(){
    if (parseInt(cross_marquee.style.top)>(actualheight*(-1)+8)) //if scroller hasn't reached the end of its height
    cross_marquee.style.top=parseInt(cross_marquee.style.top)-copyspeed+"px" //move scroller upwards
    else //else, reset to original position
    cross_marquee.style.top=parseInt(marqueeheight)+8+"px"
    }

    function initializemarquee(){
    cross_marquee=document.getElementById("vmarquee")
    cross_marquee.style.top=0
    marqueeheight=document.getElementById("marqueecontainer").offsetHeight
    actualheight=cross_marquee.offsetHeight //height of marquee content (much of which is hidden from view)
    if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){ //if Opera or Netscape 7x, add scrollbars to scroll and exit
    cross_marquee.style.height=marqueeheight+"px"
    cross_marquee.style.overflow="scroll"
    return
    }
    setTimeout('lefttime=setInterval("scrollmarquee()",30)', delayb4scroll)
    }

    if (window.addEventListener)
    window.addEventListener("load", initializemarquee, false)
    else if (window.attachEvent)
    window.attachEvent("onload", initializemarquee)
    else if (document.getElementById)
    window.onload=initializemarquee


    </script>


    <div id="marqueecontainer" onmouseover="copyspeed=pausespeed" onmouseout="copyspeed=marqueespeed">
    <div id="vmarquee" style="position: absolute; width: 96%; top: 0pt;">

    <!--YOUR SCROLL CONTENT HERE-->

    <h4> My text is here </h4>
    <!--YOUR SCROLL CONTENT HERE-->

    </div>
    </div>

  6. #6
    Join Date
    May 2007
    Location
    Boston,ma
    Posts
    2,127
    Thanks
    173
    Thanked 207 Times in 205 Posts

    Default

    that code is continuous in all browsers (safari firefox) i tested it on do you have a link to the page you have it on?

    ALSO I've found php to be similar to qbasic might want to look at that.

  7. #7
    Join Date
    Oct 2008
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Smile

    Quote Originally Posted by bluewalrus View Post
    that code is continuous in all browsers (safari firefox) i tested it on do you have a link to the page you have it on?

    ALSO I've found php to be similar to qbasic might want to look at that.

    Bluewalrus,
    Thank you very much for your reply.
    I use FireFox, and i have checked it is IE too, but it does not seems continuous...


    Thank you very much again.
    Last edited by Alumnus; 10-27-2008 at 09:53 AM.

  8. #8
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    29,133
    Thanks
    44
    Thanked 3,229 Times in 3,190 Posts
    Blog Entries
    12

  9. #9
    Join Date
    Oct 2008
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by jscheuer1 View Post

    John, thank you very much for your reply.
    I have already tried this script, but it works even worse for me. When i put my text, where the text has to be, it does not appear, or if it does appear, it starts from the middle of the marquee, or the font of the text is different or something else, always something does not work.

  10. #10
    Join Date
    Apr 2006
    Posts
    190
    Thanks
    3
    Thanked 7 Times in 7 Posts

    Default

    can you give us a link to the page where you have ur code so we can see it.
    Ryan
    Sevierville, TN

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •