MOTOSHARE 🚗🏍️
Turning Idle Vehicles into Shared Rides & Earnings
From Idle to Income. From Parked to Purpose.
Earn by Sharing, Ride by Renting.
Where Owners Earn, Riders Move.
Owners Earn. Riders Move. Motoshare Connects.
With Motoshare, every parked vehicle finds a purpose.
Owners earn. Renters ride.
🚀 Everyone wins.
The Mktime() function is an inbuilt function in PHP which is used to return the Unix timestamp for a date. The timestamp returns a long integer containing the number of seconds between the Unix Epoch (January 1, 1970, 00:00:00 GMT) and the time specified.
Syntax:
Int Mktime( $hour, $minute, $second, $month, $day, $year, $is_dst)Code language: PHP (php)
parameters
This function has seven optional parameters as mentioned below:
$hour: It is a parameter which specifies the hour.
$minute: It is a parameter which specifies the minute.
$second: It is a parameter which specifies the second.
$month: It is a parameter which specifies the month.
$day: It is a parameter which specifies the day.
$year: It is a parameter which specifies the year.
$is_dst: It is a parameter which can be set to 1 if the time is during daylight savings time (DST), or 0 if it is not.
<?php
// Using mktime() function to know the day
echo "May 21,2022 was on a " . date("l",
mktime(3, 12, 15, 5, 21, 2022));
?>
Output
May 1, 2022 was on a saturdayCode language: HTML, XML (xml)
<?php
// Using mktime() function to know the complete date
echo date("M-d-Y", mktime(0, 0, 0, 5, 21, 2022)) . "<br>";
// Using mktime() function to know the
// complete date for an out-of-range input
echo date("M-d-Y", mktime(0, 0, 0, 6, 21, 2022));
?>
Output
May-05-2022
May-06-2022
Code language: HTML, XML (xml)