472,984 Members | 2,123 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,984 software developers and data experts.

need help looking for a cross-browsers vertical scrolling script

P2P
Hi

I am wondering if someone know of a free cross-browsers vertical
scrolling script that

- is cross cross-browsers

- will call the scrolling content from an external html page or from a
url page

- will also has an option to pause when each heading on the content page
reach the top or bottom of defined scrolling window, depending on the
predefined direction the scroll is scrolling.

Will appreciate very much if someone know such a script and let me know
asap.
I spent 4 days on the net looking and trying out different vertical
scrolling script but I can't find any like the one I described above.
Thank you.

--
P2P <pl******@yahoo.com>

Mar 12 '06 #1
2 2896
VK

P2P wrote:
Hi

I am wondering if someone know of a free cross-browsers vertical
scrolling script that

- is cross cross-browsers

- will call the scrolling content from an external html page or from a
url page

- will also has an option to pause when each heading on the content page
reach the top or bottom of defined scrolling window, depending on the
predefined direction the scroll is scrolling.

Will appreciate very much if someone know such a script and let me know
asap.
I spent 4 days on the net looking and trying out different vertical
scrolling script but I can't find any like the one I described above.


So you need to program your own ;-)

<http://www.dynamicdrive.com/dynamicindex2/crosstick.htm>

may be (or may not) to be the start point.

Mar 12 '06 #2
P2P wrote:
Hi

I am wondering if someone know of a free cross-browsers vertical
scrolling script that

- is cross cross-browsers

- will call the scrolling content from an external html page or from a
url page

- will also has an option to pause when each heading on the content page
reach the top or bottom of defined scrolling window, depending on the
predefined direction the scroll is scrolling.

Will appreciate very much if someone know such a script and let me know
asap.
I spent 4 days on the net looking and trying out different vertical
scrolling script but I can't find any like the one I described above.


Here's a start. It 'works' in Firefox and old Safari, fails elegantly in
IE 5.2 (Mac). If all features not supported, content is presented in an
iFrame with scrollbars. If feature tests passed OK, iFrame has scrolling
turned off and content scrolls. Pauses when each article reaches the top,
clicking on the iFrame starts/stops the scroller.

Uses same ID for iFrame in parent as div containing all articles in iFrame
source. It would be simple to add a timer to re-load the iFrame content at
specified intervals to get new content - say when all articles have been
scrolled twice or whatever.

Parent page
===========

<title>Vertical scroller</title>
<iframe src="scroll_content.html" id="scrollHolder"
height="150" width="100px"></iframe>
content.html
============

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<title>Scroller content</title>
<style type="text/css">
body {margin: 0; padding: 0;}
#scrollHolder { }
#scrollHolder div { border: 1px solid red; }
</style>
<script type="text/javascript" src="scroller.js"></script>
<div id="scrollHolder"><div>Here's some text 0
</div><div>Here's some text 1
</div><div>Here's some text 2
</div><div>Here's some text 3
</div><div>Here's some text 4
</div><div>Here's some text 5
</div><div>Here's some text 6
</div></div>
scroller.js
===========

var scrollObj = (function()
{
var sDivID = 'scrollHolder';
var sTimer = null; // keep timer reference
var lag = 100; // milliseconds between scroll moves

var pause = 3000; // milliseconds to pause each headline
var jump = 1; // Number of px to move each time
return {
start : function()
{
var o;
var docBody = document.body || document.documentElement;
if ( docBody
&& document.getElementById
&& (o = document.getElementById(sDivID))
&& (o = o.firstChild)
&& ('number' == typeof o.offsetHeight )
&& ('number' == typeof window.scrollY )
&& ('function' == typeof window.scroll
|| 'object' == typeof window.scroll)
) {

var topT;
if ( window.top
&& (topT = window.top.document.getElementById(sDivID))
) {
topT.scrolling = 'no';
}

scrollObj.run();
docBody.onclick = scrollObj.checkScroller;
}
},

run : function()
{
var s = document.getElementById(sDivID);
window.scrollBy(0, jump);

if (s.firstChild.offsetHeight <= window.scrollY) {
window.scroll(0,0);
s.appendChild(s.firstChild);
sTimer = setTimeout('scrollObj.run();', pause);
} else {
sTimer = setTimeout('scrollObj.run();', lag);
}
},

checkScroller : function ()
{
if (sTimer){
clearTimeout(sTimer);
sTimer = null;
} else {
scrollObj.run();
}
}
};
})();

window.onload = scrollObj.start;


--
Rob
Mar 15 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Randall Smith | last post by:
When I had been programming for a few years, I realised that as much as a love to learn, I can only explore and be proficient at a limited subset of technologies. I explored different languages to...
5
by: HchC | last post by:
Not looking for a special or fancy css stylesheet. For a HTML beginner, stylesheet is still far away from now. Not even said thinking about cross browser. But, an XHTML page without stylesheet look...
16
by: Fronsac | last post by:
Hi, I've been asked in a job interview how to make C code look like C++ code, and honestly I didn't know what to answer because I have never really done a lot of C. Now, I've been searching around...
48
by: Chad Z. Hower aka Kudzu | last post by:
A few of you may recognize me from the recent posts I have made about Indy <http://www.indyproject.org/indy.html> Those of you coming to .net from the Delphi world know truly how unique and...
9
by: Tony Girgenti | last post by:
Hello I developed and tested a web application using VS.NET 2003, VB, .NET Framework 1.1.4322, ASP.NET 1.1.4322 and IIS5.1. It uses a web form. I tried doing this without any help, but i'm...
21
by: The Night Blogger | last post by:
Can someone recommend me a good API for writing a sexy looking (Rich UI like WinForms) shrink wrap application My requirement is that the application needs to look as good on Windows as on the...
2
by: David F | last post by:
I a looking for a tool that creates a cross reference table for all global functions, and optionally class methods. That is, for each function, which function(s) does it call and what function(s) is...
3
Airslash
by: Airslash | last post by:
Hello, me and 2 fellow students are busy working on our endterm project at school. The assignment consists of a cross platform multimedia application (a game in our project) that can be compiled...
9
by: jim | last post by:
I'd like to get some .net sample code that shows me how to make a complete backup of a hard drive (like my C: drive) to another location (say my D: drive) while the C: drive is in use. ...
3
by: shapper | last post by:
Hello, I am working on an ASP.MET MVC Web Application with NET 3.5 in VS 2008. I need to run some extra tasks on this project build so I download MSBuild from http://msbuildtasks.tigris.org/....
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
4
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.