Circular Scrolling Footer
Nov 29, 2005
<html>
<head>
<script type="text/javascript">
var useWidth = "400px";
var speed = 250 // greater is slower;
var message = "Now is the time for all good men to come to the aid of their country. That's one small step for man, one giant leap for mankind. Ask not what your country can do for you, ask what you can do for your country. | ";
// Remember to include the vertical bar | at the end of the message(s);
var mContainer = "";
var circleMsg = "";
var prevMsg = "";
var useFloat = "";
var xV = 0;
var xL = 0;
var msgLength = 0;
function updateMessage(){
if (circleMsg == ""){circleMsg = mContainer.lastChild.data}
else {circleMsg = prevMsg}
var separatorIdx = circleMsg.lastIndexOf('|');
if (separatorIdx == -1){separatorIdx = msgLength}
circleMsg = circleMsg.substring(1,separatorIdx);
var spliceStr = message.substring(0,msgLength-separatorIdx-1);
var dispMsg = circleMsg+spliceStr;
mContainer.removeChild(mContainer.lastChild);
mContainer.appendChild(document.createTextNode(dispMsg));
prevMsg = circleMsg+'|'+spliceStr;
setTimeout("updateMessage()",speed);
}
function startCrawl(){
mContainer.appendChild(document.createTextNode(message))
setTimeout("updateMessage()",3000); // delay before crawl start;
}
function stayHome(){
var nV = 0;
var nL = 0;
if(!document.body.scrollTop)
{
nV = document.documentElement.scrollTop;
nL = document.documentElement.scrollLeft;
}
else{
nV = document.body.scrollTop;
nL = document.body.scrollLeft;
}
if (nV == 0){window.scrollBy(0,1)}
useFloat.style.top = nV+xV+"px";
useFloat.style.left = nL+xL+"px";
setTimeout("stayHome()",50);
}
window.onload=function(){
mContainer = document.getElementById('crawl');
document.getElementById('isFloat').style.width = useWidth;
msgLength = message.length;
useFloat = document.getElementById('isFloat');
useFloat.style.left = ((screen.width-30)/2)-(parseInt(useWidth)/2)+"px";
xV = useFloat.offsetTop;
xL = useFloat.offsetLeft;
stayHome();
startCrawl();
}
</script>
</head>
<body>
<Table height=񟠠' width=ör'>
<TBody>
<TD>
<Div id='isFloat' style='position:absolute;bottom:20px;overflow:hidden;height:28px;border:solid black 1px;font-size:14pt;background-color:lightyellow;color:darkblue'>
<Div id='crawl' style='padding:3px;white-space:nowrap'> </Div>
</Div>
</TD>
</TBody>
</Table>
</body>
</html>
View 3 Replies
ADVERTISEMENT
Sep 23, 2011
I'm using this small js to scroll a div, the problem is that it goes all the way to the bottom of the page and overlapping my footer, I need it to stop before the footer. [URL]
$(function () {
var msie6 = $.browser == 'msie' && $.browser.version > 7;
if (!msie6) {
var top = $('#contact').offset().top - parseFloat($('#contact').css('margin-top').replace(/auto/, 0));
$(window).scroll(function (event) {
// what the y position of the scroll is
var y = $(this).scrollTop();
// whether that's below the form
if (y >= top) {
// if so, ad the fixed class
$('#contact').addClass('fixed');
} else {
// otherwise remove it
$('#contact').removeClass('fixed');
}});
}});
View 2 Replies
View Related
Oct 22, 2010
Im working on a project for my website where I would like to be able to change the value of a number by using js, and using getElemenById. For example:
"The taxi fare is $25"
"A hamburger is $4"
In the above sentence I would like to be able to change the value of 25 & 4 by giving them an id and then using js to increase (or decrease) their value, to allow for future inflation, without having to go back and manually change every number on lots of pages (if for example in 1 years time a hamburger is worth $6 then the info above is outdated and should be changed). If i could use a variable such as "RateUSD = 1" I could increase "1" to say "1.05" and it would increase the value of all id='USD' by 5% onload rather than having to manually change it by typing.
I so far have come up with the code below, but I think the reason it does not work is because I have created a circular equation - id='USD" is the start of the equation, but it is also in the equation itself, and it is the resulting answer, so effectively I have created "A = A*B", or in this case "25 = 25*1.1"
I chose "id" as I would like to be able to have different currencies (with different id, such as 'EURO','GBP', etc) on the same pages and on multiple pages. I'll crack it eventually, I would just like to know if I'm heading in the right direction, or is there a better method that I could use? I found plenty of example for changing text with "innerHTML", but so far I haven't seen any for updating numbers onload by calculation, except for forms, etc, which are different.
The code:
<html>
<head>
<script type="text/javascript">
function changeCurrency(){
[Code].....
I will later put the js in an external file with a link to it "...src="support-files/currencyChange.js" (or something like that), but for now I have put it on the same page.
View 11 Replies
View Related
Jan 13, 2011
I have a created a list that has both live links and links that return false and go nowhere. On the latter I want to be able to remove the arrow that is shown in the circle and hints at navigation - but I want to keep it for the live links. As an aside to this how can I then stretch the settings box for the text as it appears to only stretch across 75% on the text.
View 6 Replies
View Related
Jun 13, 2011
I've got a Google map that allows you to enter your postcode and shows results within a certain radius of that point - a very common application of the API.I have it plotting a circle to represent the area covered (easy enough), but I'd like to "grey out" the map (e.g. by applying a semi-transparent layer over it) except for the area within the circle, which shows the map as normal.
View 4 Replies
View Related
Feb 17, 2011
jQuery - Scrolling browser Window. I have two demos of scrolling page content with jQuery.
This one - [url] is scrolling the contents inside a container and it works as I wanted on Mac/PC
Code:
I need the same effect as above but I need to scroll the whole browser window.
I have a demo here - [url]
Code:
Problem here is on the Mac the transition are jumpy and it seems to flash the first yellow div before sliding up or down. Testing on a PC it will slide down but won't slide up. How can I get the whole browser window to slide up and down with a smooth transition.
View 1 Replies
View Related
Aug 6, 2010
im searching for a plugin/code example for text scrolling. I got some text in a <div> if text is longer than for example 300px it gets cut and is scrolling from start to end, stops for a second and then scrolls back, stops and all over, and if its not long enough than 300px then just displays normaly. Something similar to the Song name scrolling inin anyMP3 player.
View 2 Replies
View Related
May 11, 2006
I tried to print a page using print() and it's working, the only problem is it also prints the footer which is not allowed by my boss, so is there any way to remove the footer using any kind of language code?
View 6 Replies
View Related
Jan 7, 2010
Am struggling with speed on my site getting a overall grade of F from Yslow..
I read that moving JS into the footer can help this.. how would i go about it? I found a plugin that was supposed to do this but I don't think it works with wordpress 9 cause am still getting a F for Javascript
View 19 Replies
View Related
Dec 14, 2004
I have a problem: I have to have a footer at the very bottom and I have to have minimal, maximal width options as well. That employs two javasripts. however, the problem is with the footer. The script puts it on the very bottom even so that you can't see it in IE.
You can to scroll down to see it. So, i minimized the height of footer so that it shows up in IE. However, again, there is blank space at the very bottom. Any suggestions how to fix it? I'm no good in JavaScript at all.
View 2 Replies
View Related
Jan 5, 2010
I'm using a script to display a floating menu. I don't know how to set an offset for the footer so that it does not go all the way to the bottom. I'd like a 100px margin to the bottom of the screen. Here's my code:
[Code]...
View 3 Replies
View Related
Aug 20, 2006
I have a DIV element in a page with a lot of other stuff (the page can
scroll several times) absolutely positioned:
View 26 Replies
View Related
Jan 10, 2012
I don't know if the question is already postedI build a mini site for mobile for funny storyHow to delete the zone after footer ?I build a mini site on Samsung BadaThank for you Framework, it work very goodBut, I knwo if I can delete the zone after the footerI try with the codestyle="min-height: 677px; " in data-role="page"but it don't work.
View 1 Replies
View Related
Jun 14, 2010
I am attempting to use $load to load up a page footer that will be repeated in multiple pages.
The following seems to be working only on Safari Mac, but not on anything else... Can anyone point out what I did wrong? (The files and folders all exist)
[Page]
<!DOCTYPE HTML>
<html>
<head>
[Code].....
View 2 Replies
View Related
Sep 1, 2010
Is there any way I can stick a footer to the bottom of the browser itself, no matter the size of the browser window, ore whether the user scrolls. Its basically stuck there viewable all the time?
View 1 Replies
View Related
Dec 1, 2009
how I can achieve this static footer as seen on this site [URL]
I assume its javascript which gives you the option of hiding the bar or letting it present vearious social site links etc?
View 2 Replies
View Related
Mar 14, 2005
The amount of information I have in the footer for most of my pages has, over time, grown enough that the footer now takes up too much space vertically. Rather than completely removing the information, I would like to strip down each section of it into a single, descriptive word, and have more info about each section shown when you click on the specific word.
Essentially, it would be a mini-menu with extended information available for each menu item. I have seen show/hide javascripts that do similar things, but nothing precisely along the lines of what I am looking for, and I haven't been able to tweak any of the existing ones as I am pretty clueless about javascript beyond very basic modifications.
The main problem for me has been how to accomplish the layout I'd like for the footer:
Section1 ~ Section 2 ~ Section 3 ~ Section 4
Extended Text for Section #
The show/hide scripts in menu form that I have seen all show the extended text under each menu item, rather than having a designated area for the it regardless of which menu item was selected. But perhaps there's something out there that is more along the lines of what I need?
View 24 Replies
View Related
Nov 28, 2006
Have any of you seen that footer layer that slides up from the bottom of the screen on some pages at SitePoint? I'm trying to locate a page that does it but can't seem to do so. I'm sure it's somewhat random or lays a cookie to only appear once. Anyway, I'd like to do something similar with my site. If you've seen it, you know what I mean. How can I do this?
View 2 Replies
View Related
Jun 30, 2011
I have tried some css & html methods to place the footer at the bottom of the page no matter at which height it will be after the javascript files will run. But I cannot do it.I tried then to adjust the position of the footer dynamically after the window has loaded and the footer is placed indeed at the end of the document, but if the document gets bigger, the footer doesn't go lower.Specifically:FILE html_test.html
HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
[code]....
View 3 Replies
View Related
Jul 23, 2005
I would like all of our intranet pages to provide a link to the site
owner... and when clicked the visitor should be able to send the owner
an email.
I was using ASP to do this (see below) but I would like to not have
use the .asp extension on all 70,000 of our pages...
Can i somehow get this (or similiar) functionality using javascript?
You will notice that a _siteinfo.txt file has to be dropped into each
directory for the code to work.
This code also generates a page last modified date... but I did figure
out how to get that info using javascript. Code:
View 1 Replies
View Related
Oct 5, 2011
How to design Fixed Web Page Header and footer using jquery in ASP.Net.
View 1 Replies
View Related
Jun 29, 2010
I've got this very simple jquery script for creating a sticky footer below:
$().ready(function() {
[Code]...
This works just fine in most circumstances. However, i'm noticing one significant bug. Lets say I have my website autosaved to a tab. I start the browser and the website automatically loads. When this occurs the above script does not work.Instead the footer appears a 1/3 up the page behind the main content. After the page loads incorrectly if I refresh the browser it then loads properly. All future pages in this browser session will then be ok. Its just the first time the webpage loads when I start-up my browser that I experience this bug.
Firefox - Occurs everytime browser loads IE - Occurs when browser loads if cache has been reset
View 1 Replies
View Related
Jul 31, 2009
My problem is on this page using IE 7 & 8:[URL].. If you click the tabs, you'll see that the footer doesn't adjust accordingly. Only in IE. Works fine in Firefox (Mac & PC) and Safari Mac.
Here's the javascript:
<script type="text/javascript" charset="utf-8">
$(function () {
var tabContainers = $('div.imgswap > div');
tabContainers.hide().filter(':first').show();
$('div.imgswap ul.tabNavigation a').click(function () {
[Code]...
View 2 Replies
View Related
Nov 5, 2009
I am trying to add one image in footer of my application.
Code:
<div class="rightLinks">
<a href="#"><script src=https://seal.somesign.com/getseal?host_name=www.validsite.com&size=S&use_flash=NO&use_transparent=NO&lang=en></script></a>
</div>
But this is not working. what is wrong in it. And how can we correct it.
View 1 Replies
View Related
Dec 13, 2004
is there a way to rid of the page header (usually it's the page title and url) and the page footer (usually it's the page number and date) without having user to change from the web browser's the page setup ?
Can this be done using javascript or just html meta tags?
Also we control the contents of what is printed from a web page without having to redirect the page? Example, I have three paragraphs on a web page and I don't want the middle paragraph to be printed.
View 9 Replies
View Related
Jan 8, 2011
How to make a footer for a web that has an absolute position and automatic detect lower part of the screen. Whenever the visitor scroll the page, the footer still there and remain to it's position. Just like a header that has {position: absolute} in css.
View 3 Replies
View Related