mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-03-28 17:42:57 +01:00
in get_icon function, if the date is not in the right format, returns empty
string git-svn-id: http://piwigo.org/svn/trunk@492 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -29,6 +29,11 @@ function get_icon( $date )
|
||||
{
|
||||
global $user, $conf, $lang;
|
||||
|
||||
if (!preg_match('/\d{4}-\d{2}-\d{2}/', $date))
|
||||
{
|
||||
return '';
|
||||
}
|
||||
|
||||
list( $year,$month,$day ) = explode( '-', $date );
|
||||
$unixtime = mktime( 0, 0, 0, $month, $day, $year );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user