LoadVariables('get'); if (isset($REWRITE[1]) && $REWRITE[1] == 'Category') { if(!isset($REWRITE[4])){ $page_title = 'Famous '.str_replace("_"," ",$REWRITE[2])." Birthdays"; }else{ $page_title = 'All '.str_replace("_"," ",$REWRITE[2])." Birthdays - Page ".$REWRITE[4]; } } else if ($REWRITE[1] == 'All_Years') { $page_title = 'Famous Birthdays by Year'; } else if ($REWRITE[1] == 'All_Days') { $page_title = 'Most Popular Birthdays'; } else if ($REWRITE[1] == 'Month' && $REWRITE[3] == "Category") { $page_title = 'Famous '.str_replace("_"," ",ucfirst($REWRITE[4])).' born in '.date('F', mktime(0, 0, 0, $REWRITE[2],1,date("Y"))); if (isset($REWRITE[6])) { $page_title.=" - Page ".$REWRITE[6]; } } else { if ( $REWRITE[1] == 'Month' ) { if (!isset($REWRITE[4])){ $page_title = 'Famous People Born in '.date('F', mktime(0, 0, 0, $REWRITE[2],1,date("Y"))); }else{ $page_title = 'Famous People Born in '.date('F', mktime(0, 0, 0, $REWRITE[2],1,date("Y")))." - Page ".$REWRITE[4]; } } else if ( $REWRITE[1] == 'Year' ) { if (!isset($REWRITE[4])){ $page_title = 'Famous People Born in '.$REWRITE[2]; }else{ if ($REWRITE[3]=='Category'){$page_title = 'Famous '.ucwords($REWRITE[4]).' Born in '.$REWRITE[2];}else{ $page_title = 'Famous People Born in '.$REWRITE[2]." - Page ".$REWRITE[4];} } } else { if (isset($REWRITE[2])){ if (!isset($REWRITE[4])){ $page_title = 'Famous People Born on '.date('F', mktime(0, 0, 0, $REWRITE[1],1,date("Y")))." ".$REWRITE[2]; } else{ if (ereg("/Day/",$_SERVER['REQUEST_URI'],$regs)){ $page_title = 'Famous '.str_replace("_"," ",ucwords($REWRITE[4])).' Born on '.str_replace("-"," ",$REWRITE[2]); }else{ $page_title = 'Famous People Born on '.date('F', mktime(0, 0, 0, $REWRITE[1],1,date("Y")))." ".$REWRITE[2]." - Page ".$REWRITE[4]; }} }else { $page_title= 'Famous People Born Today, '.date("F d"); } } } include('header.php'); //debug($REWRITE); $now = date("d/m/Y"); $curentDate = date("d/m/Y"); if ( $REWRITE[1] != 'Category' && $REWRITE[1] != 'All_Years' && $REWRITE[1] != 'All_Days' && $REWRITE[1] != 'Year' && $REWRITE[1] != 'Month' ) { if (isset($REWRITE[1]) && isset($REWRITE[2])) { //month & day if (!ereg("/Day/",$_SERVER['REQUEST_URI'],$regs)){ if (checkdate($REWRITE[1],$REWRITE[2],date("Y"))) { $curentDate = $REWRITE[2]."/".$REWRITE[1]."/".date("Y"); }else{} }else{ $data=explode("-",$REWRITE[2]); $month = array( "January"=>"1","Febuary"=>"2","March"=>"3", "April"=>"4", "May"=>"5", "June"=>"6", "July"=>"7", "August"=>"8", "September"=>"9", "October"=>"10", "November"=>"11", "December"=>"12",); $curentDate=$month[$data[0]]."/".$data[1]."/".date("Y"); } } } $splitDate = @explode("/",$curentDate); $monthName = date('F', mktime(0,0,0,$splitDate[1])); $todayBirths = "SELECT COUNT(c_id) as counter FROM celebrity WHERE c_birth_day = '".$splitDate[0]."' AND c_birth_month = '".$splitDate[1]."' order by c_views desc"; $do->doQuery($todayBirths); $totalCount = $do->getRows(counter); $date = strtotime($splitDate[0].'-'.$splitDate[1].'-'.$splitDate[2]); //month if( $REWRITE[1] != 'Category' && $REWRITE[1] != 'All_Years' && $REWRITE[1] != 'All_Days' && $REWRITE[1] != 'Year' && $REWRITE[1] != 'Month' && isset($REWRITE[2])) { $splitDate[1] = $REWRITE[1]; } else if ( $REWRITE[1] == "Month" && isset($REWRITE[2]) ) { $splitDate[1] = $REWRITE[2]; } $previousDay = ($date - 86400); $nextDay = ($date + 86400); $do = new Query; ?>
doQuery($sql); $totalCelebrityesOnCurentDate = $do->getRows(counter); ?>
Birthdays Calendar
. See http://diveintomark.org/archives/2002/07/03 @list($p, $pl) = each($pn); @list($n, $nl) = each($pn); #previous and next links, if applicable if($p) $p = ''.($pl ? ''.$p.'' : $p).' '; if($n) $n = ' '.($nl ? ''.$n.'' : $n).''; $calendar = ''."\n". '\n"; if($day_name_length){ #if the day names should be shown ($day_name_length > 0) #if day_name_length is >3, the full name of the day will be printed foreach($day_names as $d) $calendar .= ''; $calendar .= "\n"; } if($weekday > 0) $calendar .= ''; #initial 'empty' days for($day=1,$days_in_month=gmdate('t',$first_of_month); $day<=$days_in_month; $day++,$weekday++){ if($weekday == 7){ $weekday = 0; #start a new week $calendar .= "\n"; } if(isset($days[$day]) and is_array($days[$day])){ @list($link, $classes, $content) = $days[$day]; if(is_null($content)) $content = $day; $calendar .= '' : '>'). ($link ? ''.$content.'' : $content).''; } else if ($day==$days){$calendar .= "";}else{$calendar .= "";} } if($weekday != 7) $calendar .= ''; #remaining "empty" days return $calendar."\n
'.$p.($month_href ? ''.$title.'' : $title).$n."
'.htmlentities($day_name_length < 4 ? substr($d,0,$day_name_length) : $d).'
 
$day$day 
\n"; } if ($REWRITE[1] == 'Month' && $REWRITE[3] == "Category") { $month=date('F', mktime(0, 0, 0, $REWRITE[2],1,date("Y")));$nr_month=$REWRITE[2]; } else{ if ( $REWRITE[1] == 'Month' ) { $month=date('F', mktime(0, 0, 0, $REWRITE[2],10,date("Y")));$nr_month=$REWRITE[2];//$day='10'; // echo $month; /////////--------------------------------------------- } } if (isset($REWRITE[2]) && $REWRITE[1]!='Month' && $REWRITE[1]!='Year' && $REWRITE[1]!='Category' ){ if (!isset($REWRITE[4])){ $month =date('F', mktime(0, 0, 0, $REWRITE[1],1,date("Y")));$nr_month=$REWRITE[1]; $day=$REWRITE[2];////////////////////////////////// } else{ if (ereg("/Day/",$_SERVER['REQUEST_URI'],$regs)){ $data=explode("-",$REWRITE[2]); $month=$data[0]; if ($month=='February'){$nr_month=2;}else{$nr_month=date("m",strtotime($month));} $day=$data[1];///////////////////////// //echo $month."-".$nr_month; }else{ $month = date('F', mktime(0, 0, 0, $REWRITE[1],1,date("Y"))); $nr_month=$REWRITE[1]; //------------------------------ }} } else{ if ($REWRITE[1]!='Month' && $REWRITE[1]!='Year'){ $month = date('F'); $nr_month=date("m"); $day=date('d');} if($REWRITE[1]=='Year'){ $month = date('F'); $nr_month=date("m"); $day=date('d'); } } echo generate_calendar(date('Y'), $nr_month, $day,'3', $month, '0', '10'); ?>
Jump to month
" class="class_font link_month">January " class="class_font link_month">February
" class="class_font link_month">March " class="class_font link_month">April
" class="class_font link_month">May " class="class_font link_month">June
" class="class_font link_month">July " class="class_font link_month">August
" class="class_font link_month">September " class="class_font link_month">October
" class="class_font link_month">November " class="class_font link_month">December
Jump to year
Most Popular Birthdays
doQuery($sql); while ($row = $do->getRows()) { $array[] = $row; } if (!empty($array)) { foreach($array as $key => $day) { ?>
"> celebrities
" class="link_month">all days
Famous Birthdays by Category
doQuery($sql); while ($row = $do->getRows()) { $array[] = $row; } if(!empty($array)) { echo ''; foreach($array as $key => $category) { ?> "; } } echo ''; } ?>
" class="class_font link_category">
" class="class_font all_years">all categories
Famous Birthdays by Year
doQuery($sql); while ($row = $do->getRows()) { $array[] = $row; } if(!empty($array)) { echo ""; foreach($array as $key => $year) { ?> "; } } echo ""; } ?>
" class="class_font born_year" style="font-size: px">
" class="class_font all_years">all years
.html" >Passed away on .html">Passed away on Passed away on
doQuery($sql); while($row = $do->getRows()) { $array[] = $row; } if(!empty($array)) { echo ''; foreach($array as $key => $name) { ?> '; } } echo ''; } else { echo ''; } ?>
No deaths available.