Closed Bug 516070 Opened 15 years ago Closed 7 years ago

<object> tag autoplays when told not to

Categories

(Core :: Audio/Video: Playback, defect)

1.9.1 Branch
x86
Linux
defect
Not set
major

Tracking

()

RESOLVED INVALID

People

(Reporter: singpolyma, Unassigned)

Details

User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.13) Gecko/2009080315 Ubuntu/9.04 (jaunty) Firefox/3.0.13 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.2) Gecko/20090803 Ubuntu/9.04 (jaunty) Shiretoko/3.5.2 When embedding an OGG/Theora video using an <object> tag Firefox autoplays, even if <param name="autoplay" value="false"> and <param name="autoStart" value="0"> are present. This presents even if they <object> tag is being used as fallback content for a <video> tag (in which case the tag should be completely ignored, not autoplayed!) Here is one of the pieces of code I tried: <video src="SWMemorial_final_low.ogg" controls height="300"> <object type="application/ogg" data="SWMemorial_final_low.ogg" height="300" width="400"> <param name="autoplay" value="false"> <param name="autoStart" value="0"> <param name="src" value="SWMemorial_final_low.ogg"> Your browser does not support video! <a href="http://getfirefox.com">Download Firefox</a> or just <a href="SWMemorial_final_low.ogg">download the video file</a> and play with <a href="http://videolan.org">VLC</a>. </object> </video> Instead of ignoring the fallback, FF3.5 started autoplaying the fallback video in behind the <video> tag video. I have confirmed this bug on Windows XP as well. Reproducible: Always Steps to Reproduce: 1. Create a page that embeds an OGG/Theora video with the <object> tag 2. Set the video not to autoplay 3. Visit the page Actual Results: The video autoplays Expected Results: The video should not autoplay
Component: General → Video/Audio
Product: Firefox → Core
QA Contact: general → video.audio
Version: unspecified → 1.9.1 Branch
See bug 487398 for the 'Object element as fallback still plays' issue. According to spec this was correct behaviour. According to bug 487398 comment 17 it's now changed so object shouldn't play.
Right, but this bug is about <object> *always autoplaying* even when told not to. Even when *not* inside a <video> tag.
Right, this is not a duplicate. I have a page that uses only embedded object tags, all of them with autoplay disabled. If flash is not installed it falls back to the ogg video object which still autoplays. I suspect this is a problem where the internal ogg player is not respecting the autoplay parameter for whatever reason. I bet the HTML parser is passing it along though. Example page (load without flash): http://nabber.org/?RWwYBg I expect this is closely related to the same problem with the <embed> tag: Bug 250855 - Mozilla should respect autoplay=false command in embed tag
Firefox 9.0 was just released, my test page is still misbehaving.
With the new H.264 support on Windows 7 and Firefox 21.0 this is also a problem with video/mp4 playback, likely the plugin that handles that as well.
Component: Audio/Video → Audio/Video: Playback
We don't support playback plugins any more, so this is no longer an issue.
Status: UNCONFIRMED → RESOLVED
Closed: 7 years ago
Resolution: --- → WORKSFORME
It seems that this is still actually a bug. HTML source with Firefox 58.0.2 will autoplay the video despite autoplay set to false: <object data='images/Better_Than_Ezra/2010-12-08_22-09-00_199.stream.mp4' width='640' height='480' type='video/mp4'> <param name='autoplay' value='false' /> <a href='images/Better_Than_Ezra/2010-12-08_22-09-00_199.stream.mp4'>Click here to view stream.<br /><img id='image' height='480' width='640' src='resize.php?base=640&amp;file=images/Better_Than_Ezra/2010-12-08_22-09-00_199.3gp' alt='images/Better_Than_Ezra/2010-12-08_22-09-00_199.3gp' /></a><br /> </object> I'm just guessing here but it looks like the Inspector shows Firefox "renders" this as a <video> tag now with empty autoplay="" and therefore the autoplay value isn't "copied" from the original <object> tag.
Reopening because this bug does not have to do with playback plugins. Rather, this bug happens when plugin is *NOT* used to play the video. (Still UNCONFIRMED because I did not confirm it myself.)
Status: RESOLVED → UNCONFIRMED
Resolution: WORKSFORME → ---
This is by design that PARAM makes sense only if a plugin is instantiated. If plugin is not used but the browser supports the media, it is embedded as if <iframe> is used. Why don't you use <video> element? (In reply to singpolyma from comment #0) > <video src="SWMemorial_final_low.ogg" controls height="300"> > <object type="application/ogg" In this example, autoplay had no effect not because fallback <object> ignore the autoplay param. Rather, fallback <object> elements nested in <video> are never activated. It's just because video has no autoplay attribute.
Status: UNCONFIRMED → RESOLVED
Closed: 7 years ago7 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.