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 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
| <html>
<head>
<title>Player Video</title>
</head>
<body>
<?php
require("connect.php3");
@mysql_connect($host,$user,$pass) or die("Impossible d établir la connection");
mysql_select_db($base1) or die("Impossible de se connecter à la base de données");
echo "<table width='680' border='0' align='center' cellpadding='0' cellspacing='0'>";
echo "<tr>";
echo "<td width='20' height='20' background='../images/SupG.png'></td>";
echo "<td width='640' background='../images/BordHaut.png' align='center'>MiechMont - Player</td>";
echo "<td width='20' background='../images/SupD.png'></td>";
echo "</tr>";
echo "<tr>";
echo "<td rowspan='2' background='../images/BordG.png'></td>";
echo "<td align='center'>";
echo "<form id='selection' name='selection'>";
echo "<select id='film' name='film' onChange='player.Filename=this.options[selectedIndex].value'>";
echo "<option value=''> =Sélectionner une vidéo=</option>";
$query = "SELECT * FROM video";
$res = mysql_query($query);
while($data = mysql_fetch_array($res)) {
$code = $data["code"];
$titre= $data["titre"];
$video= $data["video"];
echo "<option value='$video'";
if ($titre == $code) { echo "Selected"; }
echo ">$titre</option>";}
echo "</select></form>";
$query = "SELECT * FROM video";
$req = mysql_query($query)or die ("impossible de ce connecter a la base de donnée");
echo"<textarea name='comment' cols='70' rows='5' readonly='readonly' OnChange='titre1()'>";
while($data = mysql_fetch_array($req)) {
$titre1= $data["titre"];
$date= $data["date"];
$nom= $data["nom"];
$commentaire= $data["commentaire"];
if ($titre1 == "$titre") { echo "Selected"; }
echo "$nom";
echo "$date";
echo "$commentaire";
echo "</textarea><br>";
}
?>
<?php
echo "</td>";
echo "<td rowspan='2' background='../images/BordD.png'></td>";
echo "</tr>";
echo "<tr>";
echo "<td>";
echo "<div align='center'>";
?>
<Embed id="player" name="player" src="<? echo $video; ?>" width="640" height="480" autostart="1" type="application/x-mplayer2"
pluginspage="http://www.microsoft.com/windows/windowsmedia/download/defaut.asp"
ShowControls="1" ShowDisplay="0" ShowStatusBar="0" filename="<? echo $video; ?>" showtracker="1" >
</embed>
<?php
echo"</td></tr><tr>";
echo"<td height='20' background='../images/InfG.png'></td>";
echo"<td background='../images/BordBas.png'></td>";
echo"<td background='../images/InfD.png'></td>";
echo"</tr>";
echo"</table></div>";
mysql_close(); ?>
</body>
</html> |
Partager