Pausing and Resuming the jQuery / ASP.NET News Ticker | CodeGuru

Pausing and Resuming the jQuery / ASP.NET News Ticker

Many websites display a news ticker of one sort or another. A news ticker is a user interface element that displays a subset of a list of items, cycling through them one at a time after a set interval. In December 2010 I wrote an article titled Use jQuery and ASP.NET to Build a News […]

Written By
CodeGuru Staff
CodeGuru Staff
Feb 2, 2011
2 minute read
CodeGuru content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More

Many websites display a news ticker of one sort or another. A news ticker is a user interface element that displays a subset of a
list of items, cycling through them one at a time after a set interval. In December 2010 I wrote an article titled Use jQuery and ASP.NET to Build a News Ticker that
explored how to create your own news ticker widget using jQuery and ASP.NET. The news ticker’s content is defined as an unordered list
(<ul>) where each list item (<li>) represents a news headline. Once the ticker’s content is defined, having it cycle
through the head lines is as simple as calling the JavaScript function startTicker(id, numberToShow,
duration), which begins cycling the headlines in the unordered list with the specified id, showing numberToShow headlines
at a time and cycling to the next headline every duration number of milliseconds.

This ASP.NET tutorial shows how to enhance the news ticker to enable pausing and resuming. With these enhancements, the ticker can
be configured to automatically pause rotating its headlines when the user mouses over it, and to resume rotating them once the user
mouses out. Similarly, with a bit of additional markup and script you can add pause and play buttons to a ticker, allowing a user to
start and stop the ticker by clicking an image or button. To read the entire article, Pausing and Resuming the jQuery / ASP.NET News Ticker follow the link.

CodeGuru Logo

CodeGuru covers topics related to Microsoft-related software development, mobile development, database management, and web application programming. In addition to tutorials and how-tos that teach programmers how to code in Microsoft-related languages and frameworks like C# and .Net, we also publish articles on software development tools, the latest in developer news, and advice for project managers. Cloud services such as Microsoft Azure and database options including SQL Server and MSSQL are also frequently covered.

Property of TechnologyAdvice. © 2026 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.