Nulrick
10-09-2003, 11:25 AM
Does anyone know how to embed a Real Player file into an HTML page?
thanks!
thanks!
|
Click to See Complete Forum and Search --> : Embedding a Real Player file Nulrick 10-09-2003, 11:25 AM Does anyone know how to embed a Real Player file into an HTML page? thanks! Dimitri 10-09-2003, 01:48 PM Can you be more specific? What are you trying to do with the embedded real file? What kind of controls and functionality do you want? Do you want play/pause/stop buttons? Do you want it to load automatically? Is it an audio or video file? Do you want it to work across all major OS and browsers? Please be more specific. Dimitri Nulrick 10-09-2003, 02:29 PM it is a video clip with audio.. i definitely want it to playback on all major OS systems. The playback controls would also be nice.. i tried the code below, but all it does is load a black real player screen and the real player logo just flickers.. I grabbed this code from another site in which it was working.. all I changed was the name of the .rm file.. is it okay to just write in the .rm file name like i did? the original code had a long url path.. also I wonder if the problem may have something to do with the CLASSID.. Does this need to be unique for each clip? If so, where would i get it from? The .rm file I have is fine.. when I click on it, Real Player launches and plays it back w/ no problem.. i just want to embed the clip in an HTML page.. <body> <script language='JavaScript'> if (navigator.appName == "Netscape") { var player = "document.embeds[0]";} else { var player = "document.RealPlayer";} function fullscreen() { alert("To return to the original size, press the Esc key."); eval(player).SetFullScreen();} </script> <object id='RealPlayer' classid='CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA'' width='324' height='243'> <param name='src' value="crystalvid04.rm"> <param name='console' value='Clip1'> <param name='controls' value='ImageWindow'> <param name='AutoStart' value='TRUE'> <embed controls='ImageWindow' console='Clip1' type='audio/x-pn-realaudio-plugin' src="crystalvid04.rm" width='324' height='243' name='RealPlayer' autostart='true'> </embed> </object> <br> <object id='RealPlayerControls' classid='CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA' width='324' height='25'> <param name='src' value="crystalvid04.rm"> <param name='console' value='Clip1'> <param name='controls' value='ControlPanel'> <param name='AutoStart' value='TRUE'> <embed controls='ControlPanel' console='Clip1' type='audio/x-pn-realaudio-plugin' src="crystalvid04.rm" width='324' height='25' autostart='true'> </embed> </object> </body> Dimitri 10-09-2003, 02:36 PM I haven't tried to run the code yet, but I can immediately see one problem already: "crystalvid04.rm" should say "crystalvid04.rpm" (notice the letter 'p') When embedding .rm files, keep the actual RM file unchanged (e.g., "crystalvid04.rm"). But reference it as "crystalvid04.rpm" in the embedded player. Try that and let me know if that worked. Dimitri Nulrick 10-09-2003, 03:14 PM well, the fllickering stopped, but it is still just a black screen.. Code One 10-09-2003, 03:33 PM <embed src="YourVidname.file extension" hidden="false" autostart="true" loop="false"> ========================================== Check your extension I think it is actually "rma". So check that too. If your file runs in this manner, then its probably that real player files arent compatible in the script method you chose, I think due to the player not being present. In this way it is. Also first try to change the extension to rma. Before doing any of this. Good luck Code One Dimitri 10-09-2003, 04:21 PM Oh wait... you aren't streaming this file from a real server, are you? Then putting .rpm in the html isn't necessary. The code you originally gave me works, and works perfectly for me. I tested it with a local RM video file. So, unless you aren't pointing to the right location on your server (try hardcoding the URL), or unless the problem is just that your internet connection isn't fast enough to play the file in real time, then I don't know what else to suggest to you. Dimitri Nulrick 10-14-2003, 10:30 AM yes.. I am working with a local rm. file .. and the code above does seem to work fine on a pc, but I'm on a mac.. you know another thing I'm not clear on is this new "Real One" player.. I've tested my page on some computers that don't have real player installed, so I went to download it and got the Real One installer .. I'm assuming that this is the new upgraded version of real player, because there were no downloads available for real player.. so I wonder if my code above only applies to Real Player but not Real One, and that's why I'm having problems? I can watch the actual rm file in Real One and it is fine, but I just can't get it to embed the clip in an HTML page .. that's when I get the flickering problem mentioned above.. anyway, maybe this info is helpful to share w/ you if you know anything about it? Dimitri 10-14-2003, 10:47 AM Are you using IE 5.x on the Mac? I think the Mac doesn't handle embedded ActiveX controls (at least not very well.) Did it work on Netscape on the Mac? I don't own a Mac, so I can't help you with trying to make it work. Lastly, RealOne is simply the latest version of the Real Player. Dimitri Nulrick 10-14-2003, 11:23 AM yes, I'm using IE5. I have visited sites that have an embedded real player file and it works fine. I must be doing something wrong in my code.. very frustrating! Dimitri 10-14-2003, 12:49 PM Forget all that other code I gave you. Just try this instead and see if it works: <EMBED SRC="foo.rm" WIDTH="400" HEIGHT=300" CONTROLS="ImageWindow" AUTOSTART="true"> Where foo.rm is the path to your Real file. Dimitri webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |