A Mootools-powered, unobtrusive, Javascript news ticker library. /mouthful
Moostick will take in any type of <li> container (<ul>, <ol>…) and turn it into an animated news ticker, fading between each entry at a set interval.
This project is an experiment in mootoology. Quite arguably over-engineered for its core purpose, I use it to hone my MooTools skills while trying to still provide a fun and stable tool for others to use.
The unobtrusiveness aspect of the project is key in keeping the content accessible when pages are loaded without Javascript and/or CSS, whether by users or machines, and is one of Moostick’s top goals.
Download
- moostick-1.0.tar.gz: 30.5KB - tar/gzip archive
- moostick-1.0.zip: 37.2KB - zip archive
- moostick-1.0-jsdocs.tar.gz: 17.6KB - code docs
- moostick-1.0.sha1sum: 190b - File integrity signatures
Requirements: Cascading Style Sheets (CSS), Javascript and MooTools.
All historical releases can be found at:
http://labs.tekartist.org/mootools/moostick/releases/
Using Moostick
Upload Moostick to a web accessible location and include it in your [X]HTML, preferably in the head for validation but after MooTools, as follow:
<script src="moostick.js" type="text/javascript"></script>
Then simply assign an id or class of moostick to a sample unordered list.
<ul id="moostick">
<li>Sample headline</li>
<li>Another headline</li>
<li>Yet another headline</li>
<li>And a final one</li>
</ul>
See in the source of the provided examples for more fun.
The script defaults to automatically start (ondomready) and discover targeted elements through simple CSS class and id assignment (”moostick“, by default). It can also instead act as a library for developers to use with any list element in their own object oriented workflow, by passing an auto-start kill switch at include time (moostick.js?init=false). The API is documented and published with Natural Docs.
The ticking pauses when the cursor hovers over the displayed headline, and such niceties. When used an object, you can pass Moostick different intervals, effect settings, start/pause/resume/stop the ticker, tweak the script’s performance, and more.
Frequently Asked Questions
Will I get answers if I ask questions?
Magic eight ball says: it’s very likely. Feel free to send your questions and comments to labs at tekartist dot org and I’ll add the most common ones here.
Development
Moostick welcomes friendly contributors wanting to lend a hand, be it in the form of code through SVN patches, user support, platform portability testing, security consulting, etc.
The source is available under my personal Subversion repository as follow:
- Latest release: stable
- Development: unstable
- Release archives: as stable as they were when released.
Developers might also be interested in the generated code documentation (Natural Docs).
More features are already in the pipeline, such as fetching headlines through AJAX, an optionally auto-hiding previous/next toolbar, an effects bank. All while keeping the accessibility factor high on the list.
Please send your patches, questions and comments to labs at tekartist dot org.
License
Copyright © 2007 Stephane Daury
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the Software), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Anecdote
The name Moostick is intended as a double-entendre pun:
- Moo’s Tick: A MooTools-powered news ticker.
- Moostick, in English, phonetically equivalent to the French word for mosquito: moustique. A fair fit, provided how Moostick attaches itself to the targeted list as a new DOM element property.
Since the name also lends itself to puns such as Moose Tick and Moo Stick, I’m sure others will somehow follow. Software with a smile! ;)
Share this content