Précédent   Forum des professionnels en informatique > Webmasters - Développement Web > JavaScript
JavaScript Forum programmation JavaScript. Lire : Cours JavaScript, FAQ JavaScript, Toutes les FAQ JavaScript et Sources JavaScript
Partagez cette discussion sur d'autres réseaux sociaux : Viadeo Twitter Google Facebook Digg Delicious MySpace Yahoo
Réponse Proposer ce sujet en actualité
 
Outils de la discussion
Publicité
Vieux 17/03/2010, 16h18   #1
Invité de passage
 
Inscription : février 2010
Messages : 4
Détails du profil
Informations forums :
Inscription : février 2010
Messages : 4
Points : 0
Points : 0
Par défaut bouton pour séquencer d'un channel à un autre

bonjour , j'ai réaliser une page de test pour pouvoir regarder du multicast
je vous envoie le code HTML/javascript de cette page
donc je voudrais en bas des 3 lignes (play ... stop url)
ajouter un bouton séquence pour pouvoir passer d'un canal à un autre (quand j'appuie sur le bouton sa m'affiche à l'écran la video channel 1 quand jappuie encore sa passe au channel 2 ...) pouvez me donner le code pour sa je bloque ?
merci
voila le code de la page
Code :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<HTML> 
<HEAD> 
 
<BODY onload="body_load();" onkeypress="keyHandler( event );" > 
 
<FORM margin-left:30px > 
<!--p> 
 
<br> 
HDMI CEC: 
<br> 
<input type="text" value="0x43" name="UsrCtrlCode" ><input type="button" value="UsrCtrl Message Write" name="UsrCtrlCodeSet" onclick="javascript:cec_UsrCtrl_set()" > 
<input type="button" value="Toogle Volume control" name="VolCtrlToogle" onclick="javascript:cec_VolCtrlToogle()" > 
<input type="button" value="Image View On" name="ImageViewOn" onclick="javascript:cec_Viewon()" > 
<input type="button" value="Standby" name="Standby" onclick="javascript:cec_Standby()" > 
 
</p--> 
 
<p> 
<input type="button" value="Version Check" name="versions" onclick="javascript:version_check()" > <br> 
<input type="button" value="HDD test" name="HDD-test" onclick="javascript:HD_test()" > <br> 
<input type="button" value="CARDREADER test" name="CARDREADER-test" onclick="javascript:CARDREADER_test()" > <br> 
<input type="button" value="BCM5325E test" name="EthSwitch-test" onclick="javascript:EthSwitch_relink()" > <br> 
<input type="button" value="Standby test" name="STBY-test" onclick="javascript:STBY_toggle()" > <br> 
<input type="button" value="SCART8 test " name="SCART8-test" onclick="javascript:SCART8_test()" > <br> 
<input type="button" value="SCART16 test " name="SCART16-test" onclick="javascript:SCART16_change()" > <br> 
<input type="button" value="WatchDog test" name="WatchDog-test" onclick="javascript:WatchDogReset_test()" > <br> 
</p> 
 
<p> 
 
<br> 
<br> 
<input type="button" value="PLAY" name="play" onclick="javascript:stb_play()" > 
<input type="button" value="STOP" name="stop" onclick="javascript:stb_stop()" > Media:<input name="PLAY_TGT" type="text" value="ip=224.1.1.10:1234" size=36 > 
<br> 
<br> 
<input type="button" value="PLAY" name="play" onclick="javascript:stb_play()" > 
<input type="button" value="STOP" name="stop" onclick="javascript:stb_stop()" > Media:<input name="PLAY_TGT" type="text" value="ip=224.1.1.10:1234" size=36 > 
<br> 
<br> 
<input type="button" value="PLAY" name="play" onclick="javascript:stb_play()" > 
<input type="button" value="STOP" name="stop" onclick="javascript:stb_stop()" > Media:<input name="PLAY_TGT" type="text" value="ip=224.1.1.10:1234" size=36 > 
<br> 
</p> 
<p> 
 
 
<iframe id='i9000' src='' frameborder="1" width="640" height="330" > </iframe> 
 
 
</FORM> 
</BODY> 
</html>

Dernière modification par E.Bzz ; 17/03/2010 à 16h34. Motif: Balises [CODE] (cf. bouton "#" de l'éditeur)
GégéMétal est déconnecté   Envoyer un message privé Réponse avec citation 00
Vieux 29/03/2010, 17h16   #2
Membre expérimenté
 
Avatar de FMaz
 
Inscription : mars 2005
Messages : 648
Détails du profil
Informations forums :
Inscription : mars 2005
Messages : 648
Points : 527
Points : 527
La logique du code devrait ressembler à ceci:
Code :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
 
var curChan = 1;
var maxChan= 3;
nextChannel = function()
{
   curChan++;
 
   if(curChan>maxChan)
      curChan = 1;
 
   setChannel(curChan);
}
 
<input type="button" name="nextChan" value="Next Channel" onclick="nextChannel()" />
FMaz est déconnecté   Envoyer un message privé Réponse avec citation 00
Réponse Proposer ce sujet en actualité
Outils de la discussion



Fuseau horaire GMT +1. Il est actuellement 19h45.


 
 
 
 
Partenaires

Hébergement Web