Add page and api for stats about phone sended sms

This commit is contained in:
osaajani 2024-06-25 21:12:48 +02:00
parent 064d6fd941
commit 4f717ef849
11 changed files with 530 additions and 0 deletions

View file

@ -168,6 +168,26 @@ use BenMorel\GsmCharsetConverter\Converter;
return $logo;
}
/**
* Check if a string is a valid PHP date
*
* @param string $date : Datestring to validate
*
* @return bool : True if a valid date, false else
*/
public static function is_valid_date($date)
{
try
{
new \DateTime($date);
return true;
}
catch (\Exception $e)
{
return false;
}
}
/**
* Cette fonction vérifie une date.
*