The below script rotates thru <li> in a widget. http://code.google.com/p/professionalit/source/browse/trunk/customers/luisfelipe/src/luisfelipeimoveis/static/javascript/jquery.newsScroll.js?r=811 I want to modify the code (or the below config) to have the widget stop rotating through the <li> after X number of <li> - the reason is I have an AD as the bottom <li> and want it to stay on top after all the news is done rotating through the widget.. if you can think of some other option that results in the Ad remaining on top Im all ears. Here's the config script (what Im calling a config) - placed in footer <script type="text/javascript"> $('#widget').newsScroll({ speed: 1500, delay: 5000 }); // or just call it like: // $('#widget').newsScroll(); </script> Code (JavaScript): Thank you for your help!
Took a look at the code, and you can have the ad there _all_ the time, if you want, and scroll the rest beneath it - would that be a solution? It involves a slight modification of the <ul><li>-code, and some mods to the newsscroll.js-file. It can be set to scroll through all the <li> items and stop scrolling when the container for the ad reaches the top, also, of course.
That would be ideal however the widget is locked down by height 450px - and I don't want a 300px ad unit eating up all the space for the entire duration of the page-view. How can I make it "stop scrolling when the container for the ad reaches the top" - Here's the html that goes into the widget, via iframes - http://fantasyknuckleheads.com/mashed/ff-widget-make-ads.php Thx
Actually, if your ad is in the bottom of the list, and you're able to add a class to it (or some other selector), you can do this very simply. Comment out this line in the js-file: .fadeIn(300); // Fade in back in. Code (markup): and add the following to the first line in the callback function: This: $this.children('li:first') Code (markup): should be like this: $this.children('li:first').not('.ad') Code (markup): This assumes you're adding class="ad" to the <li>'s with ads in them