function getLongDateString()
{//method defined on class Date.
//Returns a date string of the form: Day DD Month,YYYY
//(e.g. Sunday 27 September, 1998)
	monthNames = new Array("gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre");
	dayNames = new Array("domenica","lunedì","martedì","mercoledì","giovedì","venerdì","sabato");
	dayOfWeek = this.getDay();
	day = dayNames[dayOfWeek];
	dateOfMonth = this.getDate();
	monthNo = this.getMonth();
	month = monthNames[monthNo];
	year = this.getYear();
	if (year < 2000)
		year = year + 1900;
//	dateStr = day+" "+dateOfMonth+" "+month+", "+year;
	if (dateOfMonth < 10)
		dateOfMonth = "0" + dateOfMonth;
	if ((monthNo+1) < 10)
		mese = "0" + (monthNo+1);
	else
		mese = monthNo+1;		
	dateStr = dateOfMonth+"."+ mese  +"."+year;
	return dateStr;
}
//register the  method in the class Date
Date.prototype.getLongDateString=getLongDateString;

function DocDate()
{ //return the document modification date (excl.time)
//as a string
	DateTimeStr = document.lastModified;
	secOffset = Date.parse(DateTimeStr);
	if (secOffset == 0 || secOffset == null) //Opera3.2
			 dateStr = "errore data";
	else
	{
		aDate = new Date();
		aDate.setTime(secOffset);
//use method defined above
		datestr = aDate.getLongDateString();
	}
	return dateStr;
}

document.write('<div id="footer" class="footertext"><center> ultimo aggiornamento sito: <span id="lastupd" class="footertext"><img src="images/indicator.gif" border="0" /></span>&nbsp;(pagina: ');
document.writeln(DocDate(),")</center>");
document.write('OLTREMARE &copy; 1999-2010 - tutti i diritti riservati</div>');
getAPage('data_ultima_mod.php','lastupd');