PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Mediaplayer in Website



I Have a Dream
26.05.07, 21:04
Ich hoffe es sind einige HTML`er unter uns. Seit einiger Zeit bastel ich an einer Homepage. Dort sind auch einige Radio`s verlinkt. Ich habe den Code des Mediaplayer in den Quelltext der Seite eingefügt. Aber immer wenn ich einen Radiolink anklicke, öffnet sich nicht der eingebaute Mediaplayer, sondern der Mediaplayer vom PC. Wie kann ich das ändern????
Bin für alle Tips dankbar.

ADCMike
27.05.07, 10:41
Hi I Have a Dream,

bin zwar kein HTML´er aber ich kann dir trotzdem helfen. :grinsend0155:

Der Grund besteht drin, dass die Datei- Endung des Links in der System-Registrierung mit dem PC- Media Player verknüpft ist.
Mit Hilfe eines Script-Plugins für den Browser wird die Verknüpfung unterbrochen, solange wie der Browser bzw. das Plugin aktiv ist.

Am besten mal von einigen Inet- Seiten mit Web- Radio, den Quell- Text anschauen. :wink:


Grüsse, Mike

I Have a Dream
27.05.07, 19:50
Ich hab schon mal bei einigen Seiten nachgesehen. Na ja, hab mir ein wenig HTML selber beigebracht, da ist es nicht so einfach fremden und komplizierten Quelltext zu durchforsten. Hast Du evtl. eine Idee wie das Script aussehen könnte? Danke für Deine Antwort.

angelfive
27.05.07, 21:43
<OBJECT ID="MediaPlayer" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95"
CODEBASE="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715"
width="150" height="53" standby="Loading Microsoft Windows Media Player components..."
type="application/x-oleobject">
<PARAM NAME="FileName" VALUE="MEINE MUSIK.mp3">
<PARAM NAME="TransparentAtStart" Value="true">
<PARAM NAME="AutoStart" Value="true">
<PARAM NAME="AnimationatStart" Value="false">
<PARAM NAME="ShowStatusBar" Value="true">
<PARAM NAME="ShowControls" Value="true">
<PARAM NAME="autoSize" Value="false">
<PARAM NAME="displaySize" Value="false">
<PARAM NAME="ShowAudioControls" Value="true">
<PARAM NAME="ShowPositionControls" Value="false">
<Embed type="application/x-mplayer2"
pluginspage="http://www.microsoft.com/Windows/Downloads/Contents/Products/MediaPlayer/"
src="media/pcyhl.mp3" Name="MediaPlayer"
width="150" height="53" transparentAtStart="1" autostart="0"
animationAtStart="0" ShowControls="true" ShowAudioControls="1"
ShowPositionControls="0" autoSize="0" ShowStatusBar="1" displaySize="false">
</embed></OBJECT>

media/pcyhl.mp3 durch deine Datei ersetzen.

I Have a Dream
27.05.07, 21:52
Also ich hab das jetzt mal eingepflegt. Eine ausgewählte Datei (media/pcyhl.mp3 durch deine Datei ersetzen) wird nun automatisch beim Aufruf der Webseite als Hintergrundmusik gestartet, meine gesetzten Radiolinks jedoch nicht. Ich glaube es kann nicht sehr schwer sein, habe aber keinen Plan.

@ Angelfive
Ich schick Dir mal per PN meine Addy, vielleicht kannst Du ja mal nachsehen was ich meine und hast evtl. noch eine gute Lösung parat. Danke für Deine Bemühungen!!!

angelfive
27.05.07, 23:34
Also eine Lösung hätte ich, auch sehr einfach. Nur die Frage hast du PHP auf dem Server. Mit HTML geht das nicht was Du vorhast. Hier kann man keine Befehle übergeben an den Mediaplayer. Mit PHP geht das sehr einfach.

I Have a Dream
28.05.07, 15:10
Das klingt ja schon sehr vielversprechend. Muß ich da die ganze Webseite neu programmieren oder läßt sich dieses PHP in HTML integrieren? Ich hab davon noch nichts gehört. Du bist auf jeden Fall der Erste der mir eine ordentliche Hilfestellung gibt. :icon_thumright:

angelfive
28.05.07, 16:29
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>test</title>
</head>

<body>
Test PHP
</body>
</html>

Kopiere den Code und speicher ihn unter test.php ab, dann schiebst Du die Datei auf deinen Webspace und versuchst die Datei im Browser auf zurufen.

Wenn dann eine Seite kommt mit "Test PHP", dann ist es ok.
Falls er dir aber einen Download "test.php" anzeigt hast du kein PHP auf dem Server laufen.

I Have a Dream
28.05.07, 20:11
Weder das eine noch das andere passiert.

angelfive
28.05.07, 20:36
Das abspielen einer einzelnen Datei klappt ja, hat er doch geschrieben.
Hier geht es um mehrere Links, die beim anklicken den Mediaplayer zum abspielen nutzen. Aber mit html, lässt sich das nicht richtig umsetzen, mit php ist das sehr einfach.

Da stand aber eben noch was anderes?

I Have a Dream
28.05.07, 21:03
Ich denke ich muß Euch mal Sinn und Zweck erklären. Guckt mal hier:
http://thomson.dreamgates.de/portal/
Sowas möchte ich auch machen. Ich hab ne Thomson IP 1101 Box mit Windows CE drauf. Meine eigene Webseite dafür soll aber anders gestaltet sein als diese, dennoch den gleichen Zweck erfüllen, nämlich Lifestreams mit der Box wiederzugeben die ich per gesetzte Links plaziert habe. Und das funktioniert nur, wenn die Links richtig an den integrierten Mediaplayer auf der HP übergeben werden. Am PC ist es ja kein Problem weil sich der PC-Mediaplayer öffnet, auf der Box bekomme ich aber eine Fehlermeldung. Ich habe schon versucht den Quelltext dieser Seite durchzusehen, aber mein HTML Editor macht da nicht mit. Ich bin schon längere Zeit an diesem Problem dran, komme aber ohne Hilfe nicht weiter.

angelfive
28.05.07, 21:03
Ich habe das mal probiert, aber da funktioniert nichts.
Ist auch nicht das was er sucht, so wie ich es verstehe soll ja kein PC-Programm extra gestartet werden, sonder im Player auf der Website abgespielt werden.

@dorfdepp hast Du das bei Dir laufen, dann kann ich mir das mal ansehen.

angelfive
28.05.07, 21:15
Ich denke ich muß Euch mal Sinn und Zweck erklären. Guckt mal hier:
http://thomson.dreamgates.de/portal/
Sowas möchte ich auch machen. Ich hab ne Thomson IP 1101 Box mit Windows CE drauf. Meine eigene Webseite dafür soll aber anders gestaltet sein als diese, dennoch den gleichen Zweck erfüllen, nämlich Lifestreams mit der Box wiederzugeben die ich per gesetzte Links plaziert habe. Und das funktioniert nur, wenn die Links richtig an den integrierten Mediaplayer auf der HP übergeben werden. Am PC ist es ja kein Problem weil sich der PC-Mediaplayer öffnet, auf der Box bekomme ich aber eine Fehlermeldung. Ich habe schon versucht den Quelltext dieser Seite durchzusehen, aber mein HTML Editor macht da nicht mit. Ich bin schon längere Zeit an diesem Problem dran, komme aber ohne Hilfe nicht weiter.

Ja, er hat es mit JavaScript gemacht. Wäre mir zu aufwendig.

angelfive
28.05.07, 21:17
Klar läuft auf meinem Board im Portal!

Na dann will ich mir das mal ansehen.:grinsend0307:


Der Realplayer geht, Winamp kann den File nicht öffnen und der Mediaplayer öffnet eine neue Seite mit den Codeinhalt.

I Have a Dream
28.05.07, 21:24
Ich stell mal meinen nicht ganz fehlerfreien Quelltext rein. Ist ja auch erstmal egal, ich will ja nur wissen wie es besser gehen könnte.
Wo muß dort angesetzt werden um das Problem in den Griff zu bekommen??????????
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta name="generator" content="SuperHTML Web Studio">
</head>
<body text=#fffbf0 vLink=#fffbf0 link=#c0c0c0 bgColor=#c0c0c0 leftMargin=0
background=http://freenet-homepage.de/XXXXXXXXX/images/blauerhintergrund.jpg
topMargin=0>
<p>&nbsp;</p>
<p>
<table height=51 cellSpacing=0 cellPadding=1 width=718 border=0>
<tr vAlign=top height=40>
<td width=285></td>
<td width=119><img height=40
src="http://freenet-homepage.de/XXXXXXXXX/images/MUSIC.gif" width=120
border=0></td>
<td></td></tr></table></p>
<div>
<table height=21 cellSpacing=0 cellPadding=1 width=717 border=0>
<tr vAlign=top>
<td width=33></td>
<td width=232><img height=40
src="http://freenet-homepage.de/XXXXXXXXX/images/80er.gif" width=120
border=0></td>
<td width=263><img height=40
src="http://freenet-homepage.de/XXXXXXXXX/images/DanceTrance.gif" width=180
border=0></td>
<td><img height=40
src="http://freenet-homepage.de/XXXXXXXXX/images/Radio.gif" width=120
border=0></td></tr></table></div>
<div>&nbsp;</div>
<div>&nbsp;</div>
<div>&nbsp;</div>
<div>&nbsp;</div>
<div>
<table height=210 cellSpacing=0 cellPadding=1 width=720 border=0>
<tr vAlign=top height=14>
<td width=9>&nbsp;</td>
<td width=23>&nbsp;</td>
<td width=206><font face="Comic Sans MS">&nbsp;<em><u><font
color=#400080><a
href="http://streamdb1.raxx.net/asx/1fm/80s_90s/128k/Listen.asx">1. FM
80s</a> </font></u></em></font></td>
<td width=17>&nbsp;</td>
<td width=241>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;<em><font
face="Comic Sans MS" color=#400080><a
href="http://streamdb1.raxx.net/asx/1fm/trance/128k/Listen.asx">1. FM
Trance</a> </font></em></td>
<td width=21>&nbsp;</td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://radioleipzig.stream.green.ch/radioleipzig.wax"><font
face="Comic Sans MS" color=#400080><em>Radio Leipzig 91.3</em></font></a>
</em></font></td>
<td width=8>&nbsp;</td>
<td>&nbsp;</td></tr>
<tr vAlign=top height=23>
<td width=9>&nbsp;</td>
<td width=23>&nbsp;</td>
<td width=206>&nbsp;<em><font face="Comic Sans MS" color=#400080>Ultimate
80s </font></em></td>
<td width=19>&nbsp;</td>
<td width=242>&nbsp;&nbsp;&nbsp;&nbsp; <font face="Comic Sans MS"
color=#400080><em><a href="http://www.radioseven.se/r7_kabel.asx">RADIO
SEVEN</a> </em></font></td>
<td width=21></td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://lsd.newmedia.tiscali-business.com/bb/redirect.lsc?content=live&media=ms&stream=ndr/live/ndr2.wma"><font
face="Comic Sans MS" color=#400080><em>NDR
2</em></font></a></em></font></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top height=24>
<td width=9></td>
<td width=23></td>
<td width=206><font face="Comic Sans MS" color=#400080><em><a
href="http://cafe80s.de/winmedia.asx"><font face="Comic Sans MS"
color=#400080><em>&nbsp;Cafe 80s</em></font></a></em></font></td>
<td width=20></td>
<td width=241>&nbsp;&nbsp;&nbsp;&nbsp;<font face="Comic Sans MS"
color=#400080><em><a href="http://www.di.fm/wma/trance.asx"><font
face="Comic Sans MS" color=#400080><em>TRANCE
CHANNEL</em></font></a></em></font></td>
<td width=21></td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="mms://ms.mdcs.dtag.de/encoder.toi.hr3_p_live"><font
face="Comic Sans MS" color=#400080><em>HR 3</em></font></a></em></font></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://www.club977.com/club977.asx"><font face="Comic Sans MS"
color=#400080><em>Club 977</em></font></a></em></font></td>
<td width=21></td>
<td width=241>&nbsp;&nbsp;&nbsp;&nbsp; <font face="Comic Sans MS"
color=#400080><em><a href="/http://ravetrax.com/hi.asx"><font
face="Comic Sans MS"
color=#400080><em>Ravetrax</em></font></a></em></font></td>
<td width=21></td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://mdr.streamfarm.net/cms/_vm100/radios/mdr/live/sputnik_cms.asx">SPUTNIK</a></em></font></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206><em><font face="Comic Sans MS" color=#400080>&nbsp;</font><a
href="http://www.radiostaddenhaag.nl/stad.asx"><font face="Comic Sans MS"
color=#400080>Radio Stad den Haag</font></a></em></td>
<td width=17></td>
<td width=241>&nbsp;&nbsp;&nbsp;&nbsp; <font face="Comic Sans MS"><a
href="http://www.pulsradio.com/pls/puls-wmp.asx" name=""><font
face="Comic Sans MS">Pulseradio</font></a></font></td>
<td width=21></td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://www.surfmusic.de"><font face="Comic Sans MS"
color=#400080><em>Surfmusic.de</em></font></a></em></font></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206>&nbsp;<font face="Comic Sans MS"><a
href="http://www.hurricanefm.nl/streams/96k.asx"><font
face="Comic Sans MS">Hurricane FM</font></a></font></td>
<td width=17></td>
<td width=241>&nbsp;&nbsp;&nbsp;&nbsp; <font face="Comic Sans MS"><a
href="http://www.garnierstreamingmedia.com/asx/streamerswitch.asp?stream=104&value=1176061108&hash=3b584e6a865c7e94a9674f88686fc7e6&crypt=6f5ff5d7bfe823cd7b9ae52eea3acd5d&digest=5a1990d217eb907b3c04efd7bb501d85"><font
face="Comic Sans MS">TMF Radio</font></a></font></td>
<td width=21></td>
<td width=161>&nbsp;<font face="Comic Sans MS" color=#400080><em><a
href="http://www.radioio.com">Radioio.com</a></em></font></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206>
<div>&nbsp;<font face="Comic Sans MS"><a
href="http://www.sky.fm/wma/the80s.asx">Sky FM 80&acute;s</a></font></div></td>
<td width=17></td>
<td width=241>&nbsp;&nbsp;&nbsp;&nbsp; <font face="Comic Sans MS"><a
href="http://lsd.newmedia.tiscali-business.com/bb/redirect.lsc?adid=0&stream=sunshinelive/livestream.wma&content=live&media=ms">Sunshine
Live</a></font></td>
<td width=21></td>
<td width=161></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206></td>
<td width=17></td>
<td width=241></td>
<td width=21></td>
<td width=161></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206></td>
<td width=17></td>
<td width=241></td>
<td width=21></td>
<td width=161></td>
<td width=8></td>
<td></td></tr>
<tr vAlign=top>
<td width=9></td>
<td width=23></td>
<td width=206></td>
<td width=17></td>
<td width=241>&nbsp;</td>
<td width=21></td>
<td width=161></td>
<td width=8></td>
<td></td></tr></table></div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</div>
<div>
<table height=85 cellSpacing=0 cellPadding=1 width=505 border=0>
<tr vAlign=top height=65>
<td width=403>
<object id=MediaPlayer style="WIDTH: 186px; HEIGHT: 83px"
codeBase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715
type=application/x-oleobject height=83
standby="Loading Microsoft Windows Media Player components..." width=186
classid=CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95>
<embed type="application/x-mplayer2"
pluginspage="http://www.microsoft.com/Windows/Downloads/Contents/Products/MediaPlayer/"
src="http://www.ohnemusik.de" Name="MediaPlayer"width="150" height="53"
transparentAtStart="1" autostart="0"animationAtStart="0"
ShowControls="true" ShowAudioControls="1"ShowPositionControls="0" autoSize="0" ShowStatusBar="1" displaySize="false">
</embed></object></td>
<td><img height=54
src="http://www.freenet-homepage.de/XXXXXXXXX/images/Frau.gif" width=60
border=0></td></tr></table></div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs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p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</div>
</body>
</html>

angelfive
28.05.07, 22:32
Also, ohne JavaScript bzw. php wird das nichts.
Das JavaScript wie auf StreamsOnTV ist sehr umfangreich, das müsste man erstmal auseinander nehmen um es für dich passend zu machen. Mit PHP, wie schon oben geschrieben, wäre das ein sehr kurzer Code und würde funktionieren. Dann solltest du dich noch mit CSS beschäftigen, um die Seite zu gestalten, aber das nur nebenbei.

I Have a Dream
28.05.07, 22:36
Bau mir doch bitte mal solch einen PHP Code ein. :wink2:

angelfive
28.05.07, 22:58
Hast Post!