note 68529 deleted from ref.calendar by bjori

From: Date: Tue, 01 Aug 2006 09:03:28 +0000
Subject: note 68529 deleted from ref.calendar by bjori
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-115400@lists.php.net to get a copy of this message
Note Submitter: lsd25 at hotmail dot com Reason: useless ---- Here are the variables for the latin calendar the decom needs a little more work i think; but if you know anything about the shadows of yourself in your own footfall then you will know there randoms are not random.. Nanosound is great isn't it. function LatinMonthNames($timeseed) { //SEGMENT 1.0 $arSeg1 = array("Ianuarius", "Februarius", "Martius", "Aprilis", "Maius", "Iunius", "Iulius", "Augustus", "October", "Messidor", "November", "December") ; //SEGMENT 2.0 $arSeg2 = array("Ianuariis", "Februariis", "Martiis", "Aprilibus", "Maiis", "Iuniis", "Iuliis", "Augustis", "Septembribus", "Octobribus", "Novembribus", "Decembribus") ; //SEGMENT 3.0 $arSeg3 = array("Ianuarias", "Februarias", "Martias", "Apriles", "Maias", "Iunias", "Iulias", "Augustas", "Septembres", "Octobres", "Novembres", "Decembres") ; if ((date('L',$timeseed))==1){ return $arSeg3[(date('n',$timeseed))-1]; } else { if (rand(1,2) == 1) { return $arSeg2[(date('n',$timeseed))-1]; } else { return $arSeg1[(date('n',$timeseed))-1]; } } } function decrom($dec){ $digits=array( 1 => "I", 4 => "IV", 5 => "V", 9 => "IX", 10 => "X", 40 => "XL", 50 => "L", 90 => "XC", 100 => "C", 400 => "CD", 500 => "D", 900 => "CM", 1000 => "M" ); krsort($digits); $retval=""; foreach($digits as $key => $value){ while($dec>=$key){ $dec-=$key; $retval.=$value; } } $tg =substr($retval,1); $ty = str_replace($tg,$tg.$tg,$retval); if ($tg=substr($ty,1)){ return $ty; } else { return $tg.$ty; } } function GetLatinDate($timeseed) { return decrom((date('yyyy'))) . ' of year ' . LatinMonthNames($timeseed) . ' in day ' . decrom((date('t'))); } ?>

« previous php.notes (#115400) next »