-
Notifications
You must be signed in to change notification settings - Fork 38
/
funciones.php
35 lines (32 loc) · 1.39 KB
/
funciones.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
/**
**
** BY iCODEART
**
**********************************************************************
** REDES SOCIALES ****
**********************************************************************
** ****
** FACEBOOK: https://www.facebook.com/icodeart ****
** TWIITER: https://twitter.com/icodeart ****
** YOUTUBE: https://www.youtube.com/c/icodeartdeveloper ****
** GITHUB: https://github.com/icodeart ****
** TELEGRAM: https://telegram.me/icodeart ****
** EMAIL: [email protected] ****
** ****
**********************************************************************
**********************************************************************
**/
// Evaluar los datos que ingresa el usuario y eliminamos caracteres no deseados.
function evaluar($valor)
{
$nopermitido = array("'",'\\','<','>',"\"");
$valor = str_replace($nopermitido, "", $valor);
return $valor;
}
// Formatear una fecha a microtime para añadir al evento, tipo 1401517498985.
function _formatear($fecha)
{
return strtotime(substr($fecha, 6, 4)."-".substr($fecha, 3, 2)."-".substr($fecha, 0, 2)." " .substr($fecha, 10, 6)) * 1000;
}
?>