| Author |
Message / Information |
Yodaminch

Quote | Reply |
| Adding Html posted on: 1/30/2003 2:00:58 PM I want to add this code to countdown to May 5,2005, the day star wars episode 3 comes out but it hasn't worked. Can it show up on top in the box with add html? the code is: <P> <SCRIPT LANGUAGE=”JavaScript”> <!-- Begin --> var date = new Date(“May 15, 2005” ; var now = new Date(); var diff = date.getTime() - now.getTime(); var days = Math.floor (diff / (1000 * 60 * 60 * 24)); document.write(days+1 + “ days until Star Wars Episode 3” ; <!-- End --> </SCRIPT></P>
|
Sharky
ChatArea.com Owner

Quote | Reply |
This message was updated on 1/30/2003 4:35:33 PM by Sharky
|
Re: Adding Html
replied on: 1/30/2003 4:34:31 PM
I copied the code you pasted there and it has flaws in it, so I redid and here is what I came up with:
<p> <script language="JavaScript"> <!-- hide from older browser var date = new Date('May 15, 2005'); var now = new Date(); var diff = date.getTime() - now.getTime(); var days = Math.floor(diff / (1000 * 60 * 60 * 24)); document.write(days + 1 + " days until Star Wars Episode 3"); //--> </script> </p>
Looks like I need to redo our posting script to not convert to smiles withing a code block...
|
Yodaminch

Quote | Reply |
|
Re: Re: Adding Html
replied on: 1/30/2003 4:46:42 PM
well i cut and pasted and added ; ) where the wink went. but still no luck. Thanks anyway
|
Elder_Code

Quote | Reply |
This message was updated on 1/30/2003 5:37:30 PM by Elder_Code
|
Re: Re: Re: Adding Html
replied on: 1/30/2003 5:37:15 PM
how about this
<br> <script language="javascript" type="text/javascript"> <!-- var date = new Date('May 15, 2005'); var now = new Date(); var diff = date.getTime() - now.getTime(); var days = Math.floor(diff / (1000 * 60 * 60 * 24)); document.write("<b>" + (days + 1) + " days until Star Wars Episode 3</b>" ); //--> </script> <br>
and that brings me to a question Javascript is enabled ?? is there limitiation i guess this is for the 'headers' how about in post or signatures ? ..im gonna try heh
|
Yodaminch

Quote | Reply |
|
Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 5:45:21 PM
elder code yours does not work either.
|
Elder_Code

Quote | Reply |
This message was updated on 1/30/2003 5:57:32 PM by Elder_Code
|
Re: Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 5:53:05 PM
humm the code does work the output : 836 days until Star Wars Episode 3 ok a few questions for ya 1: where do u wanna put this ? in the header? 2: what background color is the page 3: give me the link to your Society so i see
edit ok i found your Society try
<br> <script language="javascript" type="text/javascript"> <!-- var date = new Date('May 15, 2005'); var now = new Date(); var diff = date.getTime() - now.getTime(); var days = Math.floor(diff / (1000 * 60 * 60 * 24)); document.write("<b><font color=\"white\">" + (days + 1) + " days until Star Wars Episode 3</b></font>" ); //--> </script> <br>
note be sure to put it after your </marquee> tag
|
Yodaminch

Quote | Reply |
|
Re: Re: Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 5:59:29 PM
Thanks eldercode that one worked.
|
Elder_Code

Quote | Reply |
|
Re: Re: Re: Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 6:00:38 PM
my pleasure if u wanna center it simply add <center> at the start of the code chunk and </center> at the end of the code chunk
|
Elder_Code

Quote | Reply |
This message was updated on 1/30/2003 8:04:54 PM by Elder_Code
|
Re: Re: Re: Re: Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 7:38:46 PM
quote: and that brings me to a question Javascript is enabled ?? is there limitiation i guess this is for the 'headers' how about in post or signatures ? ..im gonna try heh
well has u can see in my signature Javascript works well, nice  i had to crush (and delete part ) of my code whats the max char allowed laWizard ? thanks
|
Sharky
ChatArea.com Owner

Quote | Reply |
|
Re: Re: Re: Re: Re: Re: Re: Re: Re: Adding Html
replied on: 1/30/2003 11:49:39 PM
I would have to check on that for you, not sure. That is nice, I didn't even know it opened up like that until I clicked on it, heh... It should open if you move your mouse over it.
btw, thanks for helping him out. the code I posted was tested today in IE and it worked just fine. He might be using NS, or another browser.
|
Elder_Code

Quote | Reply |
This message was updated on 1/31/2003 12:59:29 AM by Elder_Code
|
Adding Html and javascript!
replied on: 1/31/2003 12:12:58 AM
my pleasure for the help  i think the glitch was
document.write(days + 1 + " days until .. document.write((days + 1) + " days until ..
ya i know about the hover i got lazy a way to bypass the limit is hosting is own js file so dont mind if i need extra space ill deal with it
|
[ESJ]-Spider

Quote | Reply |
|
Re: Adding Html and javascript!
replied on: 1/31/2003 11:54:33 AM
Elder_Code... How do you make that cool text in your sig? I'm kinda newb with JavaScript or what you are using....
|
Sharky
ChatArea.com Owner

Quote | Reply |
This message was updated on 1/31/2003 12:22:54 PM by Sharky
|
Re: Re: Adding Html and javascript!
replied on: 1/31/2003 12:18:57 PM
check the F.A.Q.
|
[ESJ]-Spider

Quote | Reply |
|
Re: Re: Re: Adding Html and javascript!
replied on: 1/31/2003 12:47:59 PM
Is there other cool effects like the glow and dropshadow?
|
Elder_Code

Quote | Reply |
This message was updated on 1/31/2003 5:27:38 PM by Elder_Code
|
Re: Re: Re: Re: Adding Html and javascript!
replied on: 1/31/2003 4:47:14 PM
u putted it in the F.A.Q ? nice thinking 
for the record glow is html and css no javascript needed for glow i spoke of it because of the frame in my signature
EDIT
just a note LaWizard there more code than needed i did it fast the 1st time a short way could b (to save chars)
<font size="2" face="Verdana, Helvetica, sans-serif" style="filter:glow(color=ff0000, strength=3);height=1px"><b>title</b></font>
no need of 2 <font> tag u might want to change that in the FAQ
if someone wonders how to make shadow below is a example
<font size="2" face="Verdana, Helvetica, sans-serif" style="filter: Dropshadow(Color=#ff00000, OffX=1, OffY=1, Positive=1);height=1px"><b>title</b></font>
|
Yodaminch

Quote | Reply |
|
Re: Re: Re: Re: Re: Adding Html and javascript!
replied on: 1/31/2003 5:38:45 PM
thanks again elder code. i also added glow to the counter also. what's interesting about this glow code is when i go over my characters the avatar, reply post and edit buttons glow. i used this for myself almost to distinguish admins from mods.
|