<?php $v = "1234567890ABCDEF" $v = ( substr($v,0,2)*(2^56) + substr($v,2,2)*(2^48) + substr($v,4,2)*(2^40) + substr($v,8,2)*(2^32) + substr($v,10,2)*(2^24) + substr($v,12,2)*(2^16) + substr($v,14,2)*(2^8) / pow(1,7)*86400 ) echo $v ?>
<?php $v = "1234567890ABCDEF" $v = hexdec( substr($v,0,2)*(2^56) + substr($v,2,2)*(2^48) + substr($v,4,2)*(2^40) + substr($v,8,2)*(2^32) + substr($v,10,2)*(2^24) + substr($v,12,2)*(2^16) + substr($v,14,2)*(2^8) / pow(1,7)*86400 ) echo $v ?>
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre question<?php $v = "1234567890ABCDEF"; $v = hexdec( substr($v,0,2)*(2^56) + substr($v,2,2)*(2^48) + substr($v,4,2)*(2^40) + substr($v,8,2)*(2^32) + substr($v,10,2)*(2^24) + substr($v,12,2)*(2^16) + substr($v,14,2)*(2^8) / pow(1,7)*86400 ); echo $v; ?>
<?php $v = "1234567890ABCDEF"; $v = hexdec( substr($v,0,2)*(2^56) + substr($v,2,2)*(2^48) + substr($v,4,2)*(2^40) + substr($v,8,2)*(2^32) + substr($v,10,2)*(2^24) + substr($v,12,2)*(2^16) + substr($v,14,2)*(2^8) / pow(1,7)*86400 ); echo date('j/m/Y H:M', $v); ?>
a*(2^x), permet de décaler la valeur a de x bits
<?php $v = "1234567890ABCDEF"; $v = hexdec( substr($v,0,2)*(2^56) + substr($v,2,2)*(2^48) + substr($v,4,2)*(2^40) + substr($v,8,2)*(2^32) + substr($v,10,2)*(2^24) + substr($v,12,2)*(2^16) + substr($v,14,2)*(2^8) / pow(10,7)*86400 ); echo date('j/m/Y H:M', $v); ?>
<?php $v = "1234567890ABCDEF"; $v = hexdec(substr($v,0,2)*(2^56)) + hexdec(substr($v,2,2)*(2^48)) + hexdec(substr($v,4,2)*(2^40)) + hexdec(substr($v,8,2)*(2^32)) + hexdec(substr($v,10,2)*(2^24)) + hexdec(substr($v,12,2)*(2^16)) + hexdec(substr($v,14,2)*(2^8)) / pow(10,7)*86400 ); $date = new DateTime('1601-01-01'); $date->add(new DateInterval('P10D')); echo $date('j/m/Y H:M', $v); ?>
<?php $v = "1234567890ABCDEF"; $v = hexdec(substr($v,0,2))*(2^56) + hexdec(substr($v,2,2))*(2^48) + hexdec(substr($v,4,2))*(2^40) + hexdec(substr($v,8,2))*(2^32) + hexdec(substr($v,10,2))*(2^24) + hexdec(substr($v,12,2))*(2^16) + hexdec(substr($v,14,2))*(2^8) / (pow(10,7)*86400) ; $date = new DateTime('1601-01-01'); $date->add(new DateInterval('P10D')); echo $date('j/m/Y H:M', $v); ?>