YaBB Community and Support Forum
YaBB Home About YaBB Download YaBB YaBB Support Customize Your Forum Development Contribute to the Project
  Welcome, Guest. Please Login or Register


 
Pages: 1 2 
Topic Tools
 
How do you play midi files on chrome? (Read 6,869 times)
 Apr 15th, 2012 at 2:04am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
How do you play midi files on chrome?
Does anyone know a code that will play midi files on all browers?

The standard embed tag plays audio files on Internet Explorer, but it doesn't work on Google Chrome.

Any information would be greatly appreciated.
 
 
IP Logged  
 Reply #1 - Apr 15th, 2012 at 3:08am
There are no actions to perform.  

Dandello 
Global Moderator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Online
Posts: 1,856
Earth


YaBB 2.5
Re: How do you play midi files on chrome?
Based on the number of complaints about Chrome not playing midi files - the answer could well be that you can't. Apparently Chrome doesn't support midi files.
http://code.google.com/p/chromium/issues/detail?id=42553&can=1&q=embed%20midi&co...

I knew there was a reason - aside from not being able to find my fracking bookmarks - I didn't like Chrome.  Angry
« Last Edit: Apr 15th, 2012 at 3:09am by Dandello »  
WWW  
IP Logged  
 Reply #2 - Apr 15th, 2012 at 4:43am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
Chrome is probably the fastest web browser which is why I like to use it.

It's strange because it can play WAV and MP3 files on a browser, but not MIDI files for some reason.
 
 
IP Logged  
 Reply #3 - Apr 15th, 2012 at 8:34am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Miss Emily wrote on Apr 15th, 2012 at 4:43am:
Chrome is probably the fastest web browser which is why I like to use it.

It's strange because it can play WAV and MP3 files on a browser, but not MIDI files for some reason.

I like to use Chrome, too, but I usually go with Firefox.

The following code will play a MIDI file in Chrome, and also Safari:

Code Select All
<object data="YourSong.mid">
<param name="loop" value="10"/>
If you're seeing this, you don't have a MIDI player on your computer.
</object> 


Unfortunately, the code above doesn't seem to work in Firefox or Internet Explorer. I guess you could include two different codes so that all browsers will play your chosen MIDI file, but I haven't tested that yet.

Edited:
While the code above should work in Chrome, at least it did for me, the code in this post is more comprehensive, i.e., it will work in Chrome, Firefox, Internet Explorer, and Safari.
« Last Edit: Apr 15th, 2012 at 9:32am by Bill Myers »  
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #4 - Apr 15th, 2012 at 9:01am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
The code you provided doesn't work on Chrome for me. It displays the "If you're seeing this" error message. Does it mean I need a plug-in or something?
 
 
IP Logged  
 Reply #5 - Apr 15th, 2012 at 9:12am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
I believe that Chrome uses QuickTime for its default player, but that's probably dependent upon what plug-ins you have installed.

Regarding Chrome, and plug-ins, this page might help.
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #6 - Apr 15th, 2012 at 9:28am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Update:

I found another way to play a MIDI file in Chrome. This also works in Firefox, Internet Explorer, and Safari. I confirmed this myself in each of those browsers.

The following is what helped (referenced here):

Quote:
If you have control over the web page and can modify it, then you can tweak it so it works in all browsers:

Open the html file for the page in a text editor like Notepad.

Find this line (near the top):

<bgsound src="howgreat.mid" loop="2">

Replace it with this:

<object data="howgreat.mid" type="application/x-mplayer2" width="0" height="0">
<param name="filename" value="howgreat.mid">
<param name="playcount" value="2">
<param name="autostart" value="1">
</object>

It does exactly the same thing only it's standards compliant and will work in all browsers.

If this doesn't work for you, then it's simply a matter of installing the required plug-in, which is what others may have to do as well.
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #7 - Apr 15th, 2012 at 11:47am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
I'm surprised code works for you, but not for me.

It says "No plug-in available to display this content."

Thanks for your help but I've given up with it.
 
 
IP Logged  
 Reply #8 - Apr 15th, 2012 at 6:33pm
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Miss Emily wrote on Apr 15th, 2012 at 11:47am:
I'm surprised code works for you, but not for me.

It says "No plug-in available to display this content."

Thanks for your help but I've given up with it.

If it's any consolation, even after you correctly add the proper code to play a MIDI file, or you reference any other media file, it's not uncommon for an error message to be displayed to let that person know they need to update their browser with a specific media player, and/or a plug-in.

The good news is that once this is done for any given media file with any given browser, that browser will always be able to play that type of media.

So except for occasional updates to any given media player or plug-in, this would be a one-time installation.

Well, for each browser for any that need it.  Sigh.  Roll Eyes
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #9 - Apr 15th, 2012 at 10:01pm
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
With Internet Explorer, they let you know that you need to install a plug-in in order to play midi files, and they provide a link at the top to run.

Google Chrome shows an error message, but doesn't provide a link, therefore basic surfers wouldn't know what to do.
 
 
IP Logged  
 Reply #10 - Apr 16th, 2012 at 12:58am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Miss Emily wrote on Apr 15th, 2012 at 10:01pm:
With Internet Explorer, they let you know that you need to install a plug-in in order to play midi files, and they provide a link at the top to run.

Google Chrome shows an error message, but doesn't provide a link, therefore basic surfers wouldn't know what to do.

At least when I tried playing a MIDI file with Chrome, an option was given to play the file once, or all the time.

Additionally, after I followed the instructions that I posted here in this topic, I was also given the option to use the plug-in that had been installed for Internet Explorer.

On a related note, it seems that Chrome will play MIDI files if plug-ins have been installed for either Safari or Firefox.

If this is important to you, especially since surfers to your site will evidently get different messages depending on what they have or haven't installed, you may want to place a notice on your site to indicate that a certain song should be heard on your site, and if it isn't being heard they can download the appropriate plug-ins.

Or just give them another way to play the song, i.e., give them a direct link, and let their browser tell them what they need to play it.

To be perfectly frank, all you can really do is to do what it takes for you to hear your MIDI file in all browsers, and then not worry about whether or not other people can hear it. Otherwise, this issue will drive you nuts.

This is the nature of the Internet.  Roll Eyes
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #11 - Apr 16th, 2012 at 3:01am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
Wait a minute, it works now. I still had the "embed" code on the page and that interferred with it.

Once I removed it, and just kept the "object" code that you provided, it worked beautifully on both Chrome and Explorer.

Thank you so much Bill.
 
 
IP Logged  
 Reply #12 - Apr 16th, 2012 at 7:58am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Miss Emily wrote on Apr 16th, 2012 at 3:01am:
Wait a minute, it works now. I still had the "embed" code on the page and that interferred with it.

Once I removed it, and just kept the "object" code that you provided, it worked beautifully on both Chrome and Explorer.

Thank you so much Bill.

Oh, good! I'm glad you got it to work.  Smiley

Ironically, until you mentioned it here, I had inadvertently done the same thing, and fixed it by taking out that embedded code like you had done. I just didn't think to mention it as a "fix" for you. Still, you figured it out.


I'm reminded of a recent edit I made to add a particular sponsor to our forum. The forum seemed to be working just fine after the edit except that I suddenly realized I was no longer able to scroll through the text of a new message, nor was I am to scroll to edit an existing message. This was an irritating problem.

Almost 2 days passed before I figured out what caused the problem.  Huh

This problem affected my use of Firefox. But more importantly, it affected my use of an older version of Netscape, which I like to use because the older version renders the text of longer lines all on one line (like in YaBB's code box) ... handy for scrolling up and down in a straight line to very quickly edit a bunch of lines at once.

This didn't affect my use of Internet Explorer, but again, that browser doesn't keep longer lines of text on one line. So it had its limits when I needed to quickly edit a bunch of lines.

It finally dawned on me that I must have done something in the forum to alter the way it worked. The only change I could think of was the addition of a sponsor's ad, and sure enough, that was what had caused the problem.

So I changed the way the ad renders itself, and I was able to once again use an older version of Netscape to more quickly edits longer lines of text.

Whew!  Roll Eyes
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
 Reply #13 - Apr 16th, 2012 at 8:18am
There are no actions to perform.  

Miss Emily 
Junior Member
**
Offline
Posts: 93


None
Re: How do you play midi files on chrome?
So I guess both the "embed" and "bgsound" syntax/code should not be used anymore with many new browsers not compatible.

Yes I hear you. Things look different, or may not work on different browers which is why tests need to be done on all of them. It would be nice if all browsers were the same.
 
 
IP Logged  
 Reply #14 - Apr 16th, 2012 at 8:43am
There are no actions to perform.  

Bill Myers 
God Member
Beta Testers
*****
Offline
Posts: 1,482
Los Angeles


YaBB 2.4
Re: How do you play midi files on chrome?
Yes, that seems to be the case, and I agree; it would be nice if all browsers were the same.

I sometimes forget to test the different browsers to check how an edited page may look.

Now we have iPads and other tablets, which I might add, YaBB looks great on an iPad. Although, come to think of it, embedded media files won't play on an iPad.
 
Morning, noon, or night, have a great one! ...
WWW BillHMyers  
IP Logged  
Pages: 1 2 
Topic Tools
 

Get Yet another Bulletin Board at SourceForge.net. Fast, secure and Free Open Source software downloads Support This Project BoardMod - YaBB features and templates YaBB Codex - support on installation and usage YaBB Toolbar for your browser

YaBB Facebook Group Page

Vulnerability Scanner

Valid RSS Valid XHTML Valid CSS Powered by Perl
YaBB Chat and Support Community » Powered by YaBB 3.0 Beta!
YaBB Forum Software © 2000-2011. All Rights Reserved.