-
trembling message
i recently copied and pasted "DD Trembling Message" into a HTML code page on Dreamweaver. It did not work. Can you look at code and see what is wrong?<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<style>
.jc{
position:relative;
}
</style>
<script language="JavaScript1.2">
//Trembling message script- © Dynamic Drive (www.dynamicdrive.com)
//For full source code, 100's more DHTML scripts, and TOS,
//visit http://www.dynamicdrive.com
var ns6=document.getElementById&&!document.all
var ie=document.all
var customcollect=new Array()
var i=0
function jiggleit(num){
if ((!document.all&&!document.getElementById)) return;
customcollect[num].style.left=(parseInt(customcollect[num].style.left)==-1)? customcollect[num].style.left=1 : customcollect[num].style.left=-1
}
function init(){
if (ie){
while (eval("document.all.jiggle"+i)!=null){
customcollect[i]= eval("document.all.jiggle"+i)
i++
}
}
else if (ns6){
while (document.getElementById("jiggle"+i)!=null){
customcollect[i]= document.getElementById("jiggle"+i)
i++
}
}
if (customcollect.length==1)
setInterval("jiggleit(0)",80)
else if (customcollect.length>1)
for (y=0;y<customcollect.length;y++){
var tempvariable='setInterval("jiggleit('+y+')",'+'100)'
eval(tempvariable)
}
}
window.onload=init
</script>
</head>
<body>
<span id="jiggle0" class="jc"><<h3>Feature Title </h3></span>
</body>
</html>
-
-
Try removing this:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
and see what happens.
cr3ative
-
-
thanks creative, but when i removed the 2 top lines, nothing happened. This is now how it reads.
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<style>
.jc{
position:relative;
}
</style>
<script language="JavaScript1.2">
//Trembling message script- © Dynamic Drive (www.dynamicdrive.com)
//For full source code, 100's more DHTML scripts, and TOS,
//visit http://www.dynamicdrive.com
var ns6=document.getElementById&&!document.all
var ie=document.all
var customcollect=new Array()
var i=0
function jiggleit(num){
if ((!document.all&&!document.getElementById)) return;
customcollect[num].style.left=(parseInt(customcollect[num].style.left)==-1)? customcollect[num].style.left=1 : customcollect[num].style.left=-1
}
function init(){
if (ie){
while (eval("document.all.jiggle"+i)!=null){
customcollect[i]= eval("document.all.jiggle"+i)
i++
}
}
else if (ns6){
while (document.getElementById("jiggle"+i)!=null){
customcollect[i]= document.getElementById("jiggle"+i)
i++
}
}
if (customcollect.length==1)
setInterval("jiggleit(0)",80)
else if (customcollect.length>1)
for (y=0;y<customcollect.length;y++){
var tempvariable='setInterval("jiggleit('+y+')",'+'100)'
eval(tempvariable)
}
}
window.onload=init
</script>
</head>
<body>
<span id="jiggle0" class="jc"><h3>Feature Title </h3></span>
</body>
</html>
Last edited by mikki; 11-26-2004 at 05:46 PM.
-
-
That code works beautifully for me saved as a .htm...
cr3ative
-
-
Creative one small step for mankind. it did not work until i uploaded to browser from dreamweaver. it did not work when i viewed design option in dreamweaver. it had to be uploaded to browser. well, when i get more energy i will trek forward. thank you so much!!!
p.s. the energy is back a liitle and i want to try the rollover script. i notice that to insert into the head the script looks like this:
<style type="text/css">
.initial2{font-weight:bold;background-color:lime}
</style>
<script type="text/javascript">
<!--
/***********************************************
* Rollover background-color button Script- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
etc.................................................................
ion=url
}
//-->
</script>
my html page looks like this in head. where do i insert what do i delete.
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<style>
.jc{
position:relative;
}
</style>
<script language="JavaScript1.2">
etc...................................................
</script>
<head>
Last edited by mikki; 11-27-2004 at 02:58 AM.
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks