ajout de liste_blocks

This commit is contained in:
2019-02-09 06:08:01 +01:00
parent 24bbee0109
commit f28d91237b
3 changed files with 103 additions and 48 deletions

View File

@@ -113,7 +113,7 @@
$('#img_explorer').attr('src', 'images/loading.gif');
block_name = $('#blockSelector').val();
block_url = 'data/getBlockInfo.php';
if (block_name != 'LAST') block_url += '?block_hash='+liste_blocks[block_name];
if (block_name != 'LAST') block_url += '?block_hash='+getblocHashFromName(block_name);
$.getJSON(block_url, function( data ) {
changeExploreBlockDrawing(data);
});
@@ -139,12 +139,12 @@
<div class="container-fluid bg-grey" style="padding-top:0px;padding-bottom:10px">
<div class="row">
<div class="col-sm-4">
<br><img id="img_explorer" src="images/block_image.php" width="100%; height: auto">
<br><img id="img_explorer" src="images/loading.gif" width="100%; height: auto">
</div>
<div class="col-sm-8">
<br>
<h2>Explore the Bitcoin's Blockchain</h2>
<h4>This is a drawing of the <select id="blockSelector" onchange="javascript:changeExploreBlock()"><option value="LAST">LAST</option></select> block of the Bitcoin's Blockchain.</h4>
<h4>This is a drawing of the <select id="blockSelector" onchange="javascript:changeExploreBlock()"><option selected value="LAST">LAST</option></select> block of the Bitcoin's Blockchain.</h4>
<a href="explorer.php">Click here to see the other blocks</a>
</div>
</div>