stgzkr Posted December 30, 2019 Share Posted December 30, 2019 merhabalar htmlframe ile video gösterimini html video ile yapabiliyoruz. şunu yapabilirmiyiz. bu videonun iceriği toplam kaç saniye ve kullanıcı bunun ne kadarını izlemiş. bu verileri alıp label nesnesinde gösterebilirmiyiz. aşağıdaki gibi bir kod buldum ama bunu uyarlayamadım. yardımlarınız icin simdiden tesekkürler. <!DOCTYPE html> <html> <body> <video controls autoplay> <source src="files/traza.mp4" type="video/mp4" id="myVideo"> </video> <script type='text/javascript'> document.getElementById('myVideo').addEventListener('ended',myHandler,false); function myHandler(e) { MainForm.panelvideo.setVisible(false); // What you want to do after the event // ajaxRequest(...); } </script> </body> </html> Quote Link to comment Share on other sites More sharing options...
stgzkr Posted January 6, 2020 Author Share Posted January 6, 2020 On 12/30/2019 at 10:29 AM, stgzkr said: merhabalar htmlframe ile video gösterimini html video ile yapabiliyoruz. şunu yapabilirmiyiz. bu videonun iceriği toplam kaç saniye ve kullanıcı bunun ne kadarını izlemiş. bu verileri alıp label nesnesinde gösterebilirmiyiz. aşağıdaki gibi bir kod buldum ama bunu uyarlayamadım. yardımlarınız icin simdiden tesekkürler. <!DOCTYPE html> <html> <body> <video controls autoplay> <source src="files/traza.mp4" type="video/mp4" id="myVideo"> </video> <script type='text/javascript'> document.getElementById('myVideo').addEventListener('ended',myHandler,false); function myHandler(e) { MainForm.panelvideo.setVisible(false); // What you want to do after the event // ajaxRequest(...); } </script> </body> </html> merhaba yapmak istediğimi aşağıdaki kod blogu ile yapabildim. ilgilenen başka arkadaş olursa diye kodları paylaşıyorum. <html> <head> <style type="text/css"> #kutu { background:white; width :100%; height:100%; padding: 10px; } #myvideo { position: absolute; display: block; margin-left: auto; margin-right: auto; border: 2px solid white; margin-bottom: 5%; top: 1px; background:white; width :100%; height:100%; } </style> </head> <body> <div id="kutu"> <video id="myvideo" controls=false oncontextmenu="return false" > <source src="files/hastamemnun.mp4" type="video/ogg"> </video > </div> </body> <script> var vid = document.getElementById("myvideo"); vid.controls = false; setInterval(zamanGoster, 100); function zamanGoster () { UniForm1.UniEdit2.setValue(vid.duration); UniForm1.UniEdit1.setValue(vid.currentTime); } </script> </html> 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.