/[LeafOK_CVS]/fenglin/lib/astro.inc.php
ViewVC logotype

Contents of /fenglin/lib/astro.inc.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations)
Sat Mar 1 09:02:28 2025 UTC (12 months, 2 weeks ago) by sysadm
Branch: MAIN
Changes since 1.2: +1 -1 lines
Convert GB2312 to UTF-8

1 <?
2
3 function Date2Astro($month,$day)
4 {
5 if ($month < 1 || $month >12 || $day < 1 || $day > 31)
6 return $astro[0];
7 $dates = array(21, 20, 21, 21, 22, 22, 23, 24, 24, 24, 23, 22);
8 $astro = array("摩羯", "水瓶", "双鱼", "白羊", "金牛", "双子", "巨蟹", "狮子", "处女", "天秤", "天蝎", "射手", "摩羯");
9 if ($day < $dates[$month-1])
10 return $astro[$month-1];
11 else
12 return $astro[$month];
13 }
14
15 ?>

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1