techker Posted October 29, 2008 Share Posted October 29, 2008 hey guys i found this code on the net that shows the ctime and the date.. now is it possible to remove the date?or change it to french.. <Body> <Form Name="clock"> <Input Name="display" Size="40" Style="Font-Family:Comic Sans MS;Font-Size:24pt;Color:Blue;Font-Weight:700;Border:Solid 0px; Back-Ground:Transparent"> </Form> </Body> <Script Language="JavaScript"> <!--// function clock() { var now = new Date(); document.clock.display.value = now.toLocaleString(); timerID = setTimeout('clock()', 1000); } window.onLoad = clock(); //--> </Script> Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 30, 2008 Share Posted October 30, 2008 <Body> <Form Name="clock"> <Input Name="display" Size="40" Style="Font-Family:Comic Sans MS;Font-Size:24pt;Color:Blue;Font-Weight:700;Border:Solid 0px; Back-Ground:Transparent"> </Form> </Body> <Script Language="JavaScript"> <!--// function clock() { var now = new Date(); var date = now.toLocaleString().split(" "); document.clock.display.value = date[4] + " " + date[5]; timerID = setTimeout('clock()', 1000); } window.onLoad = clock(); //--> </Script> Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 30, 2008 Share Posted October 30, 2008 I would change <script language="javascript"> because language = javascript is depreciated. Use <script type="text/javascript'> instead. Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 30, 2008 Share Posted October 30, 2008 I would change <script language="javascript"> because language = javascript is depreciated. Use <script type="text/javascript'> instead. yep; i agree, but i was just correcting techker's code example; for the issue at hand. Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 30, 2008 Share Posted October 30, 2008 Ah I see. But you wouldn't imagine the number of people nowadays who don't bother researching depreciated objects/methods in their languages. Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 30, 2008 Share Posted October 30, 2008 Ah I see. But you wouldn't imagine the number of people nowadays who don't bother researching depreciated objects/methods in their languages. oh, i'm sure - especially for JS newbies; that is a good tip. Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 30, 2008 Share Posted October 30, 2008 I am starting to learn ajax but I haven't found the time to research the best method for creating an xmlhttprequest object. I do it in a function right now...but that is offtopic. Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 30, 2008 Share Posted October 30, 2008 I am starting to learn ajax but I haven't found the time to research the best method for creating an xmlhttprequest object. I do it in a function right now...but that is offtopic. i don't really know what the best is; when i first learned about AJAX, probably 2 years ago - i just did allot of Googling; until i found the method/routine that worked best for me and learned from that. Quote Link to comment Share on other sites More sharing options...
techker Posted October 30, 2008 Author Share Posted October 30, 2008 I would change <script language="javascript"> because language = javascript is depreciated. Use <script type="text/javascript'> instead. cool for that.but does any body now how to remove the date? Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 31, 2008 Share Posted October 31, 2008 cool for that.but does any body now how to remove the date? seriously.........? did you even read my original post? i showed you how to remove the date in it. you will have to add the window.onload event and the clock() function to it though; some how it got deleted. Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 31, 2008 Share Posted October 31, 2008 Yea i definitely remember those in your original post...where did they go lol Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 31, 2008 Share Posted October 31, 2008 no idea - must have been the code monster - tomorrow is halloween after all - lol Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 31, 2008 Share Posted October 31, 2008 I love halloween because my last name is Reese so I get free Reese's candy from this store I know because the owner knows me. I mean I seriously get bags full of them lol Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 31, 2008 Share Posted October 31, 2008 yeah, me too - just lit the jack-o-lantern a few mins ago. have a happy one BoltZ Reese; enjoy those Reese's candies. Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 31, 2008 Share Posted October 31, 2008 As im sure you are aware my first name isn't Boltz, its Eric. In fact my brother used to go here. Search account gameyin Quote Link to comment Share on other sites More sharing options...
webster08 Posted October 31, 2008 Share Posted October 31, 2008 yeah; i know Eric - it was in good fun - no worries - have a good one Quote Link to comment Share on other sites More sharing options...
BoltZ Posted October 31, 2008 Share Posted October 31, 2008 same, and because of these 3 posts of trolling, I now have reached my 20 posts per day. Ugh Javascript and html/css forums were slow today, and no one replies to my php threads Quote Link to comment Share on other sites More sharing options...
techker Posted October 31, 2008 Author Share Posted October 31, 2008 thx!! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.