1
0
mirror of https://gitlab.com/animath/si/plateforme-corres2math.git synced 2025-06-24 09:08:47 +02:00

Phase 3 : réponse aux questions

This commit is contained in:
galaxyoyo
2019-09-21 20:39:40 +02:00
parent ac48412f7e
commit 5355ba87b1
9 changed files with 261 additions and 22 deletions

View File

@ -29,4 +29,20 @@ function genRandomPhrase($size, $uppercase = false)
}
return $phrase;
}
function getExtFromMimeType($mime_type)
{
switch ($mime_type) {
case "application/pdf":
return ".pdf";
case "image/png":
return ".png";
case "image/jpg":
case "image/jpeg":
return ".jpg";
case "application/zip":
return ".zip";
}
return "";
}