Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

OGG audio in HTML 4

16 views
Skip to first unread message

Andrew Poulos

unread,
Jan 4, 2012, 2:23:51 AM1/4/12
to
I'm using this to embed OGG audio into a HTML 4 page

<object id='sound1' classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95">
<param name="filename" value="test.ogg">
<param name="autoplay" value="false">
<object width="200" height="20" data="test.ogg" type="audio/ogg">
<param name="autoplay" value="false">
</object>
</object>

It presents a number of issues. The first of which is that Chrome and
Firefox will auto-play the audio even though I've set it not to. I've
tried a number of things including using 'autostart' in place of
'autoplay, and 0 for the value. All to no avail.

How can I get this to not auto-play in Chrome and Firefox?

Andrew Poulos

dorayme

unread,
Jan 4, 2012, 4:11:32 AM1/4/12
to
In article <_oWdncQ9ZIANY57S...@westnet.com.au>,
This plays my April Showers only if I press the play button in my
FF, Safari, Chrome on my Mac:

<div>
<object type="audio/x-mp3" data="AprilShowers.mp3"
width="200" height="20">
<param name="src" value="AprilShowers.mp3">
<param name="autoplay" value="false">
<param name="autoStart" value="0">
<a href="AprilShowers.mp3">AprilShowers.mp3</a>
</object>
</div>

And only one of the lines of

<param name="autoplay" value="false">
<param name="autoStart" value="0">

are needed in my case.

--
dorayme

Andrew Poulos

unread,
Jan 4, 2012, 7:03:33 AM1/4/12
to
Thanks but I'm having the problem with OGG files and not MP3.

Andrew Poulos


dorayme

unread,
Jan 4, 2012, 11:30:58 PM1/4/12
to
In article <joudnaoqbvGD3ZnS...@westnet.com.au>,
Sorry, did not have any ogg files to test at the time. I now just
got one down and have success in FF and Chrome with the simple:

<div>
<audio src="someOggFile.ogg" controls></audio>
</div>

--
dorayme

BootNic

unread,
Jan 5, 2012, 4:06:01 AM1/5/12
to
On Wed, 04 Jan 2012 18:23:51 +1100 Andrew Poulos
<ap_...@hotmail.com> wrote:

> I'm using this to embed OGG audio into a HTML 4 page

[snip]

> <object width="200" height="20" data="test.ogg" type="audio/ogg">
> <param name="autoplay" value="false"> </object>

[snip]

> It presents a number of issues. The first of which is that Chrome
> and Firefox will auto-play the audio even though I've set it not
> to. I've tried a number of things including using 'autostart' in
> place of 'autoplay, and 0 for the value. All to no avail.
>
> How can I get this to not auto-play in Chrome and Firefox?

You will get a similar result using an iframe or opening the file directly.

In firefox inspecting it with firebug you should get a better ideal about what
is going on. Firefox is using a video element that has the autoplay attribute,
just as it would if the file was open directly.

May just be easier to use a video/audio element to begin with.


--
BootNic Thu Jan 5, 2012 04:05 am
Happiness is not something you experience, it's something you remember.
*Oscar Levant*
signature.asc

Andrew Poulos

unread,
Jan 5, 2012, 4:12:50 AM1/5/12
to
On 5/01/2012 3:30 PM, dorayme wrote:
> In article<joudnaoqbvGD3ZnS...@westnet.com.au>,
That's HTML 5 though I need HTML 4.

Andrew Poulos

dorayme

unread,
Jan 5, 2012, 4:29:33 AM1/5/12
to
In article <e-udnYmWfrUB9JjS...@westnet.com.au>,
Andrew Poulos <ap_...@hotmail.com> wrote:

> On 5/01/2012 3:30 PM, dorayme wrote:
...
> >
> > <div>
> > <audio src="someOggFile.ogg" controls></audio>
> > </div>
>
> That's HTML 5 though I need HTML 4.
>

Not doing very well, am I? Yes, you did say, HTML 4. My Pa used
to say, "Hey kid, you win some, you lose some!" <g>

--
dorayme

Adrienne Boswell

unread,
Jan 5, 2012, 2:56:13 PM1/5/12
to
dorayme <dor...@optusnet.com.au> wrote
And my friend's nine year old daughter, Noelle, says, "Hey, you win some,
you lose some, but Noelle always wins."

--
Adrienne Boswell
Arbpen Web Site Design Services - http://www.cavalcade-of-coding.info/
The Good Plate - Fresh Gourmet Recipes - http://the-good-plate.com/
Please respond to the group so others can share
0 new messages