Go Back   CodingForums.com > :: Client side development > JavaScript programming > JavaScript frameworks

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 05-14-2009, 07:27 AM   PM User | #1
Everlongdrummer
New Coder

 
Join Date: Feb 2007
Posts: 33
Thanks: 2
Thanked 0 Times in 0 Posts
Everlongdrummer is an unknown quantity at this point
Jquery News Scroller Issue

Hi guys,

I found a great jquery vertical news scroller from http://jdsharp.us/jQuery/plugins/jdNewsScroll/ which I customised for a website at http://www.bizmagic.com.au/preview/acceler8/ - (bottom right)

There is some code in it that randomises when the scroller starts scrolling.

Code:
// Randomize when the scrolling will start, afterwards it will pause by delay
this.$counter   = (Math.floor(Math.random() * 10) * 10);
However I wish for it to begin scrolling at page load, it seems kinda silly for its start time to be totally random.

The full JS is at http://www.bizmagic.com.au/preview/a...dNewsScroll.js

I can edit JS but not write it from scratch, I was hoping someone would have any idea to make it start instantly instead of randomly. Much appreciated!
Everlongdrummer is offline   Reply With Quote
Old 05-14-2009, 05:39 PM   PM User | #2
Spudhead
Senior Coder

 
Spudhead's Avatar
 
Join Date: Jun 2002
Location: London, UK
Posts: 1,856
Thanks: 8
Thanked 110 Times in 109 Posts
Spudhead is on a distinguished road
Dunno. I'd set it to 0 and see what happens.
Spudhead is offline   Reply With Quote
Old 06-02-2009, 06:03 AM   PM User | #3
Everlongdrummer
New Coder

 
Join Date: Feb 2007
Posts: 33
Thanks: 2
Thanked 0 Times in 0 Posts
Everlongdrummer is an unknown quantity at this point
Hehe thanks.

I have mucked around with different values and removed lines of code alltogether, however most changes stop the scrolling effect completely.

I guess there might need to be a little bit of rewriting rather than removing.

Totally stumped
Everlongdrummer is offline   Reply With Quote
Old 06-02-2009, 05:48 PM   PM User | #4
Eldarrion
Regular Coder

 
Join Date: Feb 2009
Location: Wheeling, IL
Posts: 358
Thanks: 5
Thanked 62 Times in 60 Posts
Eldarrion is on a distinguished road
What Spudhead suggested is the solution to your problem...

Code:
this.$counter   = 0;
Starts scrolling immediately. What exactly are you stumped about?
__________________
The way to success is to assume that there are no impossible things. After all, if you think something is impossible, you will not even try to do it.

How to ask smart questions?
Eldarrion is offline   Reply With Quote
Old 08-28-2009, 04:01 PM   PM User | #5
exiang
New to the CF scene

 
Join Date: Aug 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
exiang is an unknown quantity at this point
maybe you would like to try on this jquery news scroller

http://www.yeesiang.com/jquery.autoScroller
exiang is offline   Reply With Quote
Old 10-30-2009, 03:55 AM   PM User | #6
cowboysdude
New to the CF scene

 
Join Date: Sep 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
cowboysdude is an unknown quantity at this point
Outstanding

This is EXACTLY what I've been looking for.. You guys rock!!! I need to incorporate into something I'm doing... This is GREAT!!

Thank you!
cowboysdude is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 08:34 PM.


Advertisement
Log in to turn off these ads.