JavaScript News Scroller

Posted on 2005-04-29
Last Modified: 2008-02-01
I've developed an IFRAME named "if1". In it loads a page that must introduce a News Scroller. I like to scroll my desirect text from bottom to up, alongwith the 'pause'.  activity. On onMouseOver activity, the scrolling must pause till the onMouseOut activity is being called n the text continues scrolling from where it got paused. Could anybody plz write me the code?
Question by:adnan_from_hiit

    Author Comment

    OK its been done. Here is the solution

    <style type="text/css">  
    .link {
    .linkOver {
    <script language="JavaScript">
          var i,c=0,scrl=true;;
          function InitialiseScrollableArea(){
                i = divContainer.offsetHeight+10;      
       = i;
          function ScrollText() {
                if (!scrl) return;
                if (divContent.offsetHeight < divContainer.offsetHeight) {
                      if (i == -divContainer.offsetHeight) i = divContainer.offsetHeight+10;
                if (Math.abs(i) > divContent.offsetHeight) {
                      i = divContainer.offsetHeight+10;      


    <body onLoad="InitialiseScrollableArea()">

    <div id="divContainer">
      <div id="divContent">
            <a href="#" onMouseOver="javascript:scrl=false;this.className='linkOver';" onMouseOut="javascript:scrl=true;this.className='link'" class="link" style="color:#67777C;">Visit our newly furnished website</a>
            <a href="#" onMouseOver="javascript:scrl=false;this.className='linkOver';" onMouseOut="javascript:scrl=true;this.className='link'" class="link" style="color:#67777C;">Administrators click here</a>


    Accepted Solution

    Question Closed, 50 points refunded.
    Community Support Moderator

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Join & Write a Comment

    This article shows how to create and access 2-dimensional arrays in JavaScript.  It includes a tutorial in case you are just trying to "get your head wrapped around" the concept and we'll also look at some useful tips for more advanced programmers. …
    JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
    The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
    The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now