Thanks For Viewing,
i want to be able to get the time of the day at morning of the time yet i dont understand this can anyone help or have any other method of doing this?

$Times = array(
			   "one_day" => strtotime("0 days - ".(date("h")-1)." hours"),
			   "two_day" => strtotime("- 1 days - ".(date("h")-1)." hours"),
			   "three_day" => strtotime("- 2 days - ".(date("h")-1)." hours"),
			   "four_day" => strtotime("- 3 days - ".(date("h")-1)." hours"),
			   "five_day" => strtotime("- 4 days - ".(date("h")-1)." hours")
			   );
$lasttime=strtotime("+1 days");
foreach($Times as $name => $timestr){
	$overAll .= "<div class=\"updates\">
				<div class=\"latest\"><h2>".NiceDate($timestr)."</h2></div>
				<div class=\"latest_content\">";

$SQL = $GLOBALS['MAIN_DB']->Query("SELECT * FROM `videos` WHERE (`date`>'$timestr') AND (`date`<'$lasttime')");
if($GLOBALS['MAIN_DB']->Num($SQL)){
	while($video = $GLOBALS['MAIN_DB']->Fetch($SQL)){
		$overAll .= "<div class=\"video_index\">
						<a href=\"{$GLOBALS['SITE_URL']}watch/{$video['vid']}\"><img src=\"shared/images/vids/{$video['vid']}.image\" class=\"borderimage\" width=\"160\" height=\"120\"></a>	
							<p><strong>{$video['title']}</strong></p>
								<p><strong>Views: <span class=\"views\">{$video['views']}</span></strong></p>
								<p class=\"reg_text\">{$video['desc']}</p>

					</div>
		";
	}
}else{$overAll.="No Videos For ".NiceDate($timestr).".";}
$lasttime = $timestr;
$overAll .= "<div class=\"clear\"></div>
			 </div>
    	     </div>";
}

Thanks

    One way:

    $Times = array();
    $Times["one_day"] = mktime(0,0,1); // 00:00:01 today
    foreach(array(1 => "two_day", "three_day", "four_day", "five_day") as $num => $day)
    {
       $Times[$day] = strtotime("+$num days", $Times["one_day"]);
    }
    
    // TEST
    foreach($Times as $time)
    {
       echo date('Y/m/d H:i:s', $time) . "<br>\n";
    }
    
      Write a Reply...