Chat4all IRC forum
*
*
Home
Help
Search
Calendar
Login
Register
Welcome, Guest. Please login or register.
Did you miss your activation email?
September 03, 2010, 03:08:10 AM

Login with username, password and session length
Search:     Advanced search
4663 Posts in 769 Topics by 239 Members Latest Member: - CASEED0771 Most online today: 7 - most online ever: 154 (August 16, 2009, 11:23:19 AM)
Pages: [1]   Go Down
Print
Author Topic: Time Alternative  (Read 2293 times)
0 Members and 1 Guest are viewing this topic.
allyours
Jr. Member
**
Offline Offline

Posts: 80



View Profile WWW
« on: August 16, 2006, 06:32:19 PM »

For those of you waiting for the custom time feature here is an alternative you can use.
Code:
<script LANGUAGE="JavaScript"><!--

d = new Date();

day = d.getDay();

mon = d.getMonth();

date = d.getDate();

year = d.getYear();

hr = d.getHours();

min = d.getMinutes();



if(year<1000){year=(""+(year+11900)).substring(1,5);}

else{year=(""+(year+10000)).substring(1,5);}



if(hr==0){ap=" AM";hr=12}

else if(hr <= 11){ap=" AM"}

else if(hr == 12){ap=" PM";hr=12}

else if(hr >= 13){ap=" PM";hr-=12}



if(min <= 9){min="0"+min}



zday=new Array();

zday=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];

zmon=new Array();

zmon=["January","February","March","April","May","June","July","August","September","October","November","December"];



document.write(""+zday[day]+", "+zmon[mon]+" "+date+", "+year+" "+hr+":"+min+ap+"");

//--></script>
Place this code in your header. It will read the information from the users computer to display their own time. This will not correct the times displayed by hovering over the shouts.
This alternative may be best if you have disabled "Display Time+Users" from your CP Preferences.

You can use our clock generator to chose how you might like the time displayed.
http://allyourschat.com/webmaster/clock/
« Last Edit: August 16, 2006, 06:56:49 PM by allyours » Logged



Where friends make new friends
allyours
Jr. Member
**
Offline Offline

Posts: 80



View Profile WWW
« Reply #1 on: February 04, 2007, 07:07:36 PM »

We very much appreciate the addition of chat4all to give us the option to set our shoutbox to a local time. We have activated ours for GMT-5 which is Eastern Time USA. Knowing that only a portion of those viewing and using the shoutbox are in that zone we decided to keep the above script in our header thus allowing them to see their own time read from their computers CMOS clock.

Thanks for the wonderful shoutbox and updated features. Keep up the great work. Smile
Logged



Where friends make new friends
Pages: [1]   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.10 | SMF © 2006-2009, Simple Machines LLC
Oxygen design by Bloc
Valid XHTML 1.0! Valid CSS!
Page created in 0.067 seconds with 18 queries.