Comment extraire le script Java Elemet
var MyDiv1 = document.getElementById('myid');
alert(MyDiv1.getAttribute('data-variableid2'));
Crazy Cardinal
var MyDiv1 = document.getElementById('myid');
alert(MyDiv1.getAttribute('data-variableid2'));
<div id="myid" data-variableid2="1234"> </div>