Last Comment Bug 240408 - Allow browser to handle <embed> content
: Allow browser to handle <embed> content
Product: Core
Classification: Components
Component: Layout: Misc Code (show other bugs)
: Trunk
: All All
-- normal with 2 votes (vote)
: ---
Assigned To: tor
: Jet Villegas (:jet)
: 231171 (view as bug list)
Depends on:
  Show dependency treegraph
Reported: 2004-04-13 08:38 PDT by tor
Modified: 2004-11-10 11:03 PST (History)
11 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

allow browser to handle <embed> content (2.09 KB, patch)
2004-04-13 08:39 PDT, tor
dbaron: review-
jst: superreview+
Details | Diff | Splinter Review
only allow handing of svg <embed> (2.68 KB, patch)
2004-11-05 14:37 PST, tor
dbaron: review+
Details | Diff | Splinter Review
adjust per dbaron's review comments (5.01 KB, patch)
2004-11-05 17:18 PST, tor
jst: superreview+
Details | Diff | Splinter Review

Description User image tor 2004-04-13 08:38:22 PDT
We should allow the browser to handle the content of <embed> frames
as we do for <object>.  This would allow a mozilla with native SVG
to handle the SVG content of pages that were written for use with
a plugin.
Comment 1 User image tor 2004-04-13 08:39:58 PDT
Created attachment 146016 [details] [diff] [review]
allow browser to handle <embed> content
Comment 2 User image Johnny Stenback (:jst, 2004-05-13 18:36:27 PDT
Comment on attachment 146016 [details] [diff] [review]
allow browser to handle <embed> content

Nice! :-)

Comment 3 User image Jonathan Watt [:jwatt] 2004-07-12 11:07:30 PDT
*** Bug 231171 has been marked as a duplicate of this bug. ***
Comment 4 User image David Baron :dbaron: ⌚️UTC-8 2004-07-14 14:11:40 PDT
This seems like it would make EMBED work with text/html too, which I don't think
we want to do.

Also, are people really using EMBED for plugin SVG content, rather than OBJECT?
Comment 5 User image tor 2004-07-14 14:38:31 PDT
The Adobe SVG demos, the Adobe "SVG Site Spotlight", and the W3C's SVG
test suite all are using <embed>.

Why would an embed of text/html be a bad thing?  A roundabout way of
doing an iframe, but doesn't seem harmful.
Comment 6 User image P. Damian Cugley 2004-07-15 02:36:09 PDT
Using the 'object' tag to embed SVG in web pages crashes Safari 1.0, so I have
been forced to switch to using 'embed' [1].  Since updates to Safari are not
available to users of Mac OS X version 10.2, I have to assume Safari 1.0 will be
in circulation for some years to come.


For some reason, almost all browsers have had disastrously buggy implementations
of 'object' at some point; Safari is merely the most recent.  As a result,
'embed' is a lot more prevelant than the W3C would have liked.
Comment 7 User image David Baron :dbaron: ⌚️UTC-8 2004-07-17 17:58:49 PDT
I don't think we should be adding additional capabilities to deprecated features
of HTML if nobody wants them, since it just encourages use of the deprecated
Comment 8 User image David Baron :dbaron: ⌚️UTC-8 2004-08-04 12:29:38 PDT
Comment on attachment 146016 [details] [diff] [review]
allow browser to handle <embed> content

review- per comment 7
Comment 9 User image Hixie (not reading bugmail) 2004-09-22 04:18:11 PDT
dbaron: Would it make you feel better if we put <embed> into a spec 
and said it was no longer deprecated?
Comment 10 User image Jungshik Shin 2004-10-25 11:37:53 PDT
Some standard-conscious people are forced to use 'embed' because MS IE refuses
to 'render' the following straightforward construct using 'object' complaining
about 'insecure' content being fed to ActiveX control.

 <object data="test.mp3" type="audio/mpeg" height="239" width="45">
You are expected to listen to ..... </object>

To avoid that, one has to use a construct like this:

<object id="Player" CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6"
			width="239" height="45" title="Playing Music">
		<param name="URL" value="music.mp3" />
		<param name="autoStart" value="true" />

			<embed src="music.mp3" type="application/x-mplayer2" 
			width="239" height="45"
			pluginspage = "">
			<noembed>Music to be played</noembed>

Again, those caring about the standard compliance would love to use 'object' in
place of 'embed', but MS IE does NOT ignore the inner 'object' and complain
about 'the security' although it should just ignore it because it can process
the outer object.  
Comment 11 User image Boris Zbarsky [:bz] (still a bit busy) 2004-10-25 12:33:50 PDT
What does that have to do with this bug?  This bug is about objects that would
be handled by Mozilla itself (like, say, text/html objects).
Comment 12 User image tor 2004-11-05 14:37:10 PST
Created attachment 164791 [details] [diff] [review]
only allow handing of svg <embed>
Comment 13 User image David Baron :dbaron: ⌚️UTC-8 2004-11-05 15:29:12 PST
Comment on attachment 164791 [details] [diff] [review]
only allow handing of svg <embed>

>+#ifndef MOZ_SVG
>   // only do the following for the object tag
>   if (aContent->Tag() != nsHTMLAtoms::object)
>     return rv;

Just drop this entirely.  It makes things more confusing, and it's not

Also, while you're there, it looks like IsSupportedImage and
IsSupportedDocument can be static.  If that's correct, please make them static
(one less argument passed).
Comment 14 User image tor 2004-11-05 17:18:09 PST
Created attachment 164802 [details] [diff] [review]
adjust per dbaron's review comments
Comment 15 User image Johnny Stenback (:jst, 2004-11-09 16:55:20 PST
Comment on attachment 164802 [details] [diff] [review]
adjust per dbaron's review comments

Comment 16 User image tor 2004-11-10 11:03:33 PST
Checking in nsObjectFrame.cpp;
/cvsroot/mozilla/layout/html/base/src/nsObjectFrame.cpp,v  <--  nsObjectFrame.cpp
new revision: 1.475; previous revision: 1.474
Checking in nsObjectFrame.h;
/cvsroot/mozilla/layout/html/base/src/nsObjectFrame.h,v  <--  nsObjectFrame.h
new revision: 1.32; previous revision: 1.31

Note You need to log in before you can comment on or make changes to this bug.