0

hello everybody can someone help me please.

hello everybody can someone help me please. I would to create an html page that contain two divs with two table.they must toggle every 5 s .and when the users click the toggle must stop, and when it's a double click the toggle must continue. i create the toggle function with jquery this is how i did, : var intervalID = setInterval(function() { $("#mydiv2").toggle(); $("#mydiv1").toggle(); }, 5000); setTimeout(function() { clearInterval(intervalID); }, 20000); .

1st Feb 2019, 3:51 PM
ABDELMOUGHIT GARDAM
ABDELMOUGHIT GARDAM  - avatar
2 Antworten
+ 1
//can you please attach your whole source code
4th Feb 2019, 10:15 PM
Sudarshan Rai
Sudarshan Rai - avatar
0
<div id="aob"> <div id="mydiv1" style=" float:left; height:300px; padding:30px;display: none" onclick="abo();"> <table id="table1"> <tr> <th align="center">NOM CLIENT</th> <th align="center">NUM</th> <th align="center">STATUS</th> </tr> </table> </div> <div id="mydiv2" style="width: 300px; float:left; padding: 30px;" onmousemove="rca();" onclick="abc();"> <table id="table2" ;> <tr> <th align="center">NOM CLIENT</th> <th align="center">NUM</th> <th align="center">STATUS</th> </tr> </table> </div> <script> var table=[["dsds",8,"NOK"],["dssd",5,"NOK"],["dsds",8,"ok"],["sd",9,"NOK"],["ds",8,"NOK"],["dssds",8,"NOK"],["ds",8,"NOK"]]; for (var i=0;i<table.length;i++){ document.getElementById("table1").innerHTML+="<tr><td>"+table[i][0]+"</td><td>"+table[i][1]+"</td><td>"+table[i][2]+"</td></tr>"; } var i; for (var i=0;i<table.length;i++){ if(table[i][2]=="NOK") console.log("Les cases suivantes sont nok name:"+table[i][0]); } </script> <script> var table=[["abcd",11,"NOK"],["abcde",5,"NOK"],["sdqdsq",8,"ok"],["dqsqsdq",9,"NOK"],["dssqds",8,"NOK"],["dsqds",8,"NOK"],["dsqsd",8,"NOK"]]; for (var j=0;j<table.length;j++){ if(table[j][2]=="ok") alert("Les cases suivantes sont ok name:"+table[j][0]);} </script> <script> var intervalID = setInterval(function() { $("#mydiv2").toggle(); $("#mydiv1").toggle(); }, 5000); setTimeout(function() { clearInterval(intervalID); },30000); setInterval(function(){ location.reload(); }, 40000); </script> </div> </body> </html>
5th Feb 2019, 10:05 AM
ABDELMOUGHIT GARDAM
ABDELMOUGHIT GARDAM  - avatar