[thelist] Sarafi/MSIE/NS Site Check & Need Javascript to display... Monday, 21 September,2003 etc

John C Bullas jcbullas at nildram.co.uk
Thu Dec 11 14:30:50 CST 2003


Colleagues

Need a Jscript that will be Safari & NS/MSIE friendly to display the 
current date on a page
without tripping over Safari......

Can everyone see this page ok?

http://www.cohousingresources.com/adapted.htm

http://www.cohousingresources.com/adapted.shtml parsed with SSI time date 
insert.. easy peasy.. ok for Safari?

(QUESTION how the hell do I get a non UNIX server with evidence of 
FRONTPAGE AT WORK to parse *.htm files?)

I am not the original author, just jumped in to recover a "munged" page or 
two... FrontPage won't touch this site again!!!

IN PASSING, a Safari user said they were getting errors from the JS 
time/date insert running on the main sites pages....

here: http://www.cohousingresources.com/ and as below.......

WHY?????

<SCRIPT LANGUAGE="Javascript"><!--

// ***********************************************
// AUTHOR: WWW.CGISCRIPT.NET, LLC
// URL: http://www.cgiscript.net
// Use the script, just leave this message intact.
// Download your FREE CGI/Perl Scripts today!
// ( http://www.cgiscript.net/scripts.htm )
// ***********************************************

// Get today's current date.
var now = new Date();

// Array list of days.
var days = new 
Array('Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday');

// Array list of months.
var months = new 
Array('January','February','March','April','May','June','July','August','September','October','November','December');

// Calculate the number of the current day in the week.
var date = ((now.getDate()<10) ? "0" : "")+ now.getDate();

// Calculate four digit year.
function fourdigits(number)	{
	return (number < 1000) ? number + 1900 : number;
	

returner=document.write("<br>")
								}

// Join it all together
today =  days[now.getDay()] + ","  + "<br>" +
               months[now.getMonth()] + " " +
                date + ", " +
                 (fourdigits(now.getYear())) ;

// Print out the data.
document.write(today);

//--></SCRIPT>



More information about the thelist mailing list