Melodeon.net Forums

Please login or register.

Login with username, password and session length
Advanced search  

News:

Welcome to the new melodeon.net forum

Pages: 1 [2]   Go Down

Author Topic: Major scientific breakthrough in Wales!  (Read 5141 times)

0 Members and 1 Guest are viewing this topic.

Andrew Wigglesworth

  • Hero Member
  • *****
  • Offline Offline
  • Posts: 1101
  • 07
    • My website
Re: Major scientific breakthrough in Wales!
« Reply #20 on: February 27, 2013, 11:42:40 AM »

The simplest way to embed audio so that it plays on the page rather than simply linking to a file is to use HTML 5 audio tags.

Code: [Select]
<audio controls>
  <source src="my_audio_file.ogg" type="audio/ogg">
  <source src="my_audio_file.mp3" type="audio/mpeg">
</audio>

The reason that you should offer it in both Ogg Vorbis and mp3 formats is the Microsoft does not support Vorbis and because of licensing issues Firefox does not support mp3.
Andrew,
I'm interested in what you say about Firefox and mp3 format; I don't think I have a problem using Firefox. I run the Lizzie Dripping website which includes links to audio samples from the website music page. These are in mp3 format and play perfectly fine in the web browsers I have tested: Firefox, Safari, IE, Netscape (remember that one?). I've only ever uploaded mp3 files to the hosting server, not .ogg files.


OK, a quickie (if I can manage that :D ) since I'm off out in a short while.

On your website you are using Javascript and object/embed tags to embed a media player plugin into the web page.

For instance, on the computer I'm using now it pulls in a plugin that launches the "Gecko Media Player" that uses Mplayer to play the audio. It is Mplayer (or whatever audio player is called by the plugin on other computers) that is playing the audio *not* the web browser.

When using HTML 5, no plugins or external programmes are used. It is the web browser itself that is playing the audio file. Since the embedding code is far simpler and the results much more predictable it is a far better way of embedding audio on a web page.

A few other comments ... see, I can't help myself  ::)

People have come up with all sorts convoluted and "clever" ways of embedding audio (and video) onto web pages. Sadly, for many people these "clever" ways fail, are discriminatory or are disruptive to their computer.

Object/embed tags and Javascript pulling in media plugins has been one way, but this is very hit and miss. It assumes that the web browser is interpreting Javascript (or is even capable of interpreting it) and has media plugins (or is even capable of using media plugins).

It's a complicated system with many points of failure, not least of which is the capacity to crash the web browser. For instance, the Lizzie Dripping audio player pages crash the browser on my laptop ... "pop" and it's gone.

If the web browser is not interpreting Javascript or it does not have a media plugin, then the player on the Lizzie Dripping website simply fails, silently. There is no explanation and no access to the audio files. Even when it successfully plays the file there is very little predictability over what actually happens. Here it downloads the whole file and simply starts playing it with no controls to pause, stop or restart it.

If using Javascript then a noscript tag should be used to offer the information (the audio file in this case) to browsers not running Javascript. A descriptive alternative in text should be used with object tags so that if the web browser does not support the plugin (or applet) then the user can still access the content.

I used the word "discriminatory", not to be pejorative, it's simply a description of one of the real consequences of web accessibility failures. Blind and partially-sighted users (for instance) do not access websites in the same way that that fully-sighted people do. They often do not use the same web browsers, use screen readers or if they use the same browsers, they do not have them set up in the same way.

This was meant to be a few quick comments so I'm going to heavily edit myself here ... basically, if you are using "clever" ways of presenting information or media files then there should be alternatives for people who cannot use these ways.

Steve, please don't take my comments in the wrong way. I'm not commenting upon anyones character or implying bad intentions. Sadly, with all the competing interests and, quite frankly, the anti-social behaviour of many companies this whole area can be a minefield. Some of us deal with these issues daily, so we know a bit more about what is going on, that's all.  (:)

edited: spelling
« Last Edit: February 27, 2013, 11:49:10 AM by Andrew Wigglesworth »
Logged

Andrew Wigglesworth

  • Hero Member
  • *****
  • Offline Offline
  • Posts: 1101
  • 07
    • My website
Re: Major scientific breakthrough in Wales!
« Reply #21 on: February 27, 2013, 11:51:08 AM »

Oh, I should have said, really nice tunes and playing on the Lizzie Dripping site.

Thanks for that, I enjoyed it.

Chris Ryall

  • "doc 3-row"
  • French Interpreter
  • Hero Member
  • *****
  • Offline Offline
  • Posts: 11154
  • Wirral UK
    • Chris Ryall
Re: Major scientific breakthrough in Wales!
« Reply #22 on: February 27, 2013, 11:59:43 AM »

Having put some thought and much experimentation into this in December when voicing ME .. All of what Andrew says. This was a complete mess made worse by Apple and Microsoft trying to maintain a proprietary edge in what should be a simple  "standard"

HTML5 <audio> tags are not 100% ready, but are the clear way forward, and what I've installed. You need .ogg and .mp3 versions of your clips, easy with Audacity.

I'd say 95% of browsers will display and play something sensible already. If they don't my advice is that it be left as a non compliance problem for them rather than tax yourself with any workaround.

A line suggesting "up to date browser version" to enjoy the music makes much sense. As the <audio> tag is intended as universal that will make bugs self fixing.   HTML5 will solve so many other diddly issues that I think all will have to fall in line over the coming year. :|glug
Logged
  _       _    _      _ 

Steve_freereeder

  • Content Manager
  • Hero Member
  • ***
  • Offline Offline
  • Posts: 7511
  • MAD is inevitable. Keep Calm and Carry On
    • Lizzie Dripping
Re: Major scientific breakthrough in Wales!
« Reply #23 on: February 28, 2013, 01:37:12 AM »

Thanks Andrew and Chris both for your replies. I have very little technical knowledge when it comes to html coding. I can do the basics, but mostly I just use 'Freeway' software to create the coding as if I were using a word processor. However, I have learned a bit more as a result of this exchange, thank you.  (:) 

Steve, please don't take my comments in the wrong way. I'm not commenting upon anyones character or implying bad intentions. Sadly, with all the competing interests and, quite frankly, the anti-social behaviour of many companies this whole area can be a minefield. Some of us deal with these issues daily, so we know a bit more about what is going on, that's all.  (:)
Of course not - don't worry, your post did not come over in a bad light at all. On the contrary, it was most informative, thanks.

Oh, I should have said, really nice tunes and playing on the Lizzie Dripping site.

Thanks for that, I enjoyed it.
Thanks! I passed on your comment to my fellow musician Celia at our Lizzie Drips practice earlier this evening. (:)
Logged
Steve
Sheffield, UK.
www.lizziedripping.org.uk
Pages: 1 [2]   Go Up
 


Melodeon.net - (c) Theo Gibb; Clive Williams 2010. The access and use of this website and forum featuring these terms and conditions constitutes your acceptance of these terms and conditions.
SimplePortal 2.3.5 © 2008-2012, SimplePortal