/    Sign up×
Community /Pin to ProfileBookmark

New willing but frustrated…

Hi…I really like this fade in text but I can not get it to link to any page. Getting page unknown no matter what I put into it.

Here is the code..Not sure what stays what goes…I have tried every variation. Even when I click on the link that is in the original script it takes me to a page not found. It works on the site but not in my html editor. I have as I said tried everything I know possible.

Any help sure will be appreciated.

Thank you Tink

[URL=Here it is thank you]http://javascript.internet.com/messages/colorful-text-fader.html[/URL]

to post a comment
JavaScript

7 Comments(s)

Copy linkTweet thisAlerts:
@96turnerriNov 10.2003 — i think this is what you mena not too sure tho :rolleyes:

<HEAD>

<SCRIPT LANGUAGE="JavaScript" type="text/javascript">

var msg=new Array()

msg[0]="<CENTER>Want Better Value For Money?...</CENTER>";

msg[1]="<CENTER>Why Not Visit....</CENTER>";

msg[2]="<CENTER>Your Domain</CENTER>";

msg[3]="<CENTER>Right Now</CENTER>";

// set your first set of colors. Use as many or as few as you wish.

var colors1=new Array("ffffff", "eeeeff", "ddddff", "ccccff", "bbbbff", "aaaaff", "9999ff",

"8888ff", "7777ff", "6666ff", "5555ff", "4444ff", "3333ff","2222ff", "1111ff", "0000ff")

//set your second set of colors

// *** must have exactly the same number of colors as the array above ***

var colors2=new Array("ffffff", "ffeeee", "ffdddd", "ffcccc", "ffbbbb", "ffaaaa", "ff9999",

"ff8888", "ff7777", "ff6666", "ff5555", "ff4444", "ff3333", "ff2222", "ff1111", "ff0000")

//set the height of the display in pixels

high=60;

//set the width of the display in pixels

wide=350;

//set the pixel coordinates for the upper left hand corner of the display

Xpos=220;

Ypos=180;

// move the display away from the edges of the background

pad=15;

// set the background color of the display

bgcol="ffffff";

//add a background image if you want.

// *** for no image, just leave empty quotes (ex. cellbg=""; ) ***

cellbg="faderbg.jpg";

// set the font

fntFam="verdana,helvetica,arial";

fntSize=14;

// set how how many seconds you want the message to stay remain at totality.

pause=1.5;

icolor=0;

mcolor=1;

imsg=0;

spWidth=wide-(2*pad);

totality=false;

glowing=true;

var theMsg="";

var cellcontent="";

pause=pause*
1000;

if(cellbg.length>4){cellbg=" background="+cellbg}

else{cellbg="";}

function doPause(){

totality=false; t=setTimeout("changecolor()",pause);

}

function initiate(){

getContentColor();

getMsg();

getCellContent();

if(document.all){

msgbg.innerHTML=cellcontent;

msgfade.innerHTML=theMsg;

msgbg.style.posLeft=Xpos;

msgbg.style.posTop=Ypos;

msgfade.style.posLeft=Xpos+pad;

msgfade.style.posTop=Ypos+pad;

t=setTimeout("changecolor()",50);}

if(document.layers){

document.msgbg.document.write(cellcontent);

document.msgbg.document.close();

document.msgfade.document.write(theMsg);

document.msgfade.document.close();

document.msgbg.left=Xpos;

document.msgbg.top=Ypos;

document.msgfade.left=Xpos+pad;

document.msgfade.top=Ypos+pad;

t=setTimeout("changecolor()",100);}

}

function changecolor(){

if(totality==true){doPause();}

else{

getMsg();

getContentColor();

if(document.all){

msgfade.innerHTML=theMsg;

t=setTimeout("changecolor()",50);}

if(document.layers){

document.msgfade.document.write(theMsg);

document.msgfade.document.close();

t=setTimeout("changecolor()",70);}

}

}

function getFadeColor(){

icolor=icolor-1;

if(mcolor==1){contentcolor=colors1[icolor];}

else{contentcolor=colors2[icolor];}

}

function getGlowColor(){

icolor=icolor+1;

if(mcolor==1){contentcolor=colors1[icolor];}

else{contentcolor=colors2[icolor];}

}

function changemsg(){

if(imsg==msg.length-1){imsg=0; mcolor=1;}

else if(imsg != msg.lenght-1 && mcolor==1){imsg=imsg+1; mcolor=0;}

else{imsg=imsg+1; mcolor=1;}

}

function getContentColor(){

if(icolor==colors1.length-1 && glowing==true){

getFadeColor(); glowing=false; totality=true;}

else if(icolor < colors1.length && glowing==true){

getGlowColor();}

else if(icolor < 1 && glowing==false){changemsg(); getGlowColor(); glowing=true;}

else{getFadeColor();}

}

function getMsg() {

theMsg="<span style='font-size:"+fntSize+"pt; font-family:"+fntFam+"; width:"+spWidth+";'>"

theMsg+="<B><font color="+contentcolor+">"+msg[imsg]+"</font></B> "

theMsg+="</span>"

}

function getCellContent(){

cellcontent="<TABLE height="+high+

" width="+wide+" bgcolor="+bgcol+" cellpadding=0 cellspacing=0><TR><TD"+cellbg+"> </TD></TR></TABLE>"}

</script>

</HEAD>

<BODY onLoad="initiate()">

<a href="http://www.yourdomain.com">

<DIV id=msgbg style="position: absolute;"></DIV>

<DIV id=msgfade style="position: absolute;"></DIV></a>
Copy linkTweet thisAlerts:
@Tink8005authorNov 11.2003 — Everything works accept when I try to enter a link. What I need is for someone to check out what I entered and hopefully find out why when I take it to my editor the link code does not work.

Maybe put a code that works here for me to copy...thanks
Copy linkTweet thisAlerts:
@96turnerriNov 11.2003 — what do you mean? i tried and tested this code and it works, what link you talking about?
Copy linkTweet thisAlerts:
@Tink8005authorNov 12.2003 — It works for me too if I try it on the source page. Javascripts

But when I copy the code into my HTML editor the link goes to page unkown, as does any other link I try to put in place of it...
Copy linkTweet thisAlerts:
@96turnerriNov 12.2003 — that could be because some programs dont copy text from webpages that well put it into notepad then into html editor
Copy linkTweet thisAlerts:
@Tink8005authorNov 13.2003 — Thank you...see I knew there was something I did not try...

I found another script ...but going to try this in the furture...good to keep a copy anyway.

Now I can actually spend some time reading in here.

Thanks Again!!
Copy linkTweet thisAlerts:
@96turnerriNov 13.2003 — ok not a problem ?
×

Success!

Help @Tink8005 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.19,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...