function getWorkingDays($startDate, $endDate){
$begin=strtotime($startDate);
$end=strtotime($endDate);
if($begin>$end){
echo "tartdate is in the future!
";
return 0;
}else{
$no_days=0;
$weekends=0;
while($begin<=$end){
$no_days++; // no of days in the given interval
$what_day=date("N",$begin);
if($what_day>6) { // 6 and 7 are weekend days
$weekends++;
};
$begin+=86400; // +1 day
};
$working_days=$no_days-$weekends;
return $working_days;
}
}
Html, JAVA,DOTNET,Javascript, PHP, and JQuery Scripts and its issues with solutions
Friday, 11 July 2014
How to calculate no of working days in php?
How to find last day of month in jquery datetime picker?
function getLastDayOfYearAndMonth(year, month){
return(new Date((new Date(year, month + 1, 1)) - 1)).getDate();
}
Thursday, 10 July 2014
How to find your mobile number?
உங்கள் மொபைல் எண் மறந்துவிட்டதா? *********************************** "உங்கள் மொபைல் எண் திரையில் தோன்ற அழுத்துங்கள்" Idea சேவையைப் பயன்படுத்துபவர்கள் *1# Bsnl சேவையைப் பயன்படுத்துபவர்கள் *888# Aircel சேவையைப் பயன்படுத்துபவர்கள் *131# Videocon சேவையைப் பயன்படுத்துபவர்கள் *1# Airtel சேவையைப் பயன்படுத்துபவர்கள் *121*9# Reliance சேவையைப் பயன்படுத்துபவர்கள் *1# Virgin Mobile சேவையைப் பயன்படுத்துபவர்கள் *1# Vodafone சேவையைப் பயன்படுத்துபவர்கள் *131*0# Tata DoComo சேவையைப் பயன்படுத்துபவர்கள் *580#
Subscribe to:
Comments (Atom)
Feet/Inches to Meters Converter & Lbs to Kgs Converter
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <title>Feet/Inches ⇄...
-
<?php $to = "somebody@example.com, somebodyelse@example.com"; $subject = "HTML email"; $message = " <h...
-
document.onkeydown = myKeyDownHandler; function myKeyDownHandler(event){ alert(event.keyCode) }
-
<?php $date1 = "2015-01-23 00:20"; $date2 = "2015-01-23 05:30"; $seconds = strtotime($date2) - strtotime($date1);...