Ce qui a pour effet de placer le block dans le cache // --- $the_block = blockchain::getSpecialBlock($block_hash); if ($the_block === FALSE) die(); if ($block_hash == 'LAST') { $max = 0; // On se met en retard d'au moins un bloc ... while(!file_exists(DATA_PATH.'/json/'.$the_block->hash.'.zip')) { $block_hash = $the_block->prev_block; $the_block = blockchain::getSpecialBlock($block_hash); if ($the_block === FALSE) die(); // Mais pas plus de 5 blocs de retard ... $max += 1;if ($max > 5) break; } } echo $the_block->hash." ".$the_block->height." ".$the_block->n_tx.PHP_EOL; ?>