Bug 11803 - Incorrect use of alternate content inside the <object> element
Summary: Incorrect use of alternate content inside the <object> element
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 420+
Hardware: Macintosh OS X 10.4
: P2 Normal
Assignee: Nobody
URL: http://misc.xstandard.com/apple/alter...
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2006-12-11 08:28 PST by Vlad Alexander
Modified: 2010-10-13 17:37 PDT (History)
6 users (show)

See Also:


Attachments
Patch (3.62 KB, patch)
2010-10-08 15:29 PDT, Adam Barth
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vlad Alexander 2006-12-11 08:28:28 PST
Form controls inside the <object> element should not send data to the server if the object is rendered correctly. Content inside the <object> element is alternate content not additonal content to the <object> element. In this example, data from the <textarea> should not be sent to the server if the <object> element is rendered correctly:

<object data="logo.gif" type="image/gif" width="180" height="60">
<textarea id="abc" name="abc" rows="5" cols="70">Hello World!</textarea>
</object>

Test case at:
http://misc.xstandard.com/apple/alternate-content1.asp

We are a browser plug-in vendor and would very much like to use the above construct with our plug-in called XStandard. IE and Opera already support correct use of alternate content in the <object> element.
Comment 1 Vlad Alexander 2007-03-21 14:26:55 PDT
To further clarify the request for this bug fix, when our plug-in is not installed on the client, we need to provide a "textarea" in its place. To do this, we use the fallback mechanism built into the "object" element. For example:

<object type="application/x-xstandard" name="editor1">
<textarea name="editor1"></textarea>
</object>

Both "object" and "textarea" need to have the same value in the "name" attribute because our plug-in is used in existing content management systems (CMS) where it is very difficult or impossible to change the server-side code to received HTTP POST data from 2 form controls instead of one for what is really one control. Since both controls have the same "name", the server will received double the data.
Comment 2 David Kilzer (:ddkilzer) 2007-03-22 15:00:02 PDT
Vlad filed this in Radar as:  <rdar://problem/4268878>
Comment 3 Robert Blaut 2008-06-13 11:53:40 PDT
I tested the problem in the latest WebKit and it looks that the bug is already fixed.

Any confirmations?
Comment 4 Alexey Proskuryakov 2008-06-13 13:38:30 PDT
I'm still seeing this issue with WebKit r34513 (i.e., I'm seeing "abc = Hello World!" in the result). Firefox behaves the same.
Comment 5 Robert Blaut 2008-06-13 14:10:39 PDT
(In reply to comment #4)
> I'm still seeing this issue with WebKit r34513 (i.e., I'm seeing "abc = Hello
> World!" in the result). Firefox behaves the same.
> 

Argh... You are right. Description of the bug was unclear for me, so I incorrectly interpret result of the test case :(
Comment 6 Ian 'Hixie' Hickson 2008-11-26 04:40:49 PST
this is invalid per html5
Comment 7 Adam Barth 2010-10-08 15:29:32 PDT
Created attachment 70300 [details]
Patch
Comment 8 WebKit Commit Bot 2010-10-13 17:36:59 PDT
Comment on attachment 70300 [details]
Patch

Clearing flags on attachment: 70300

Committed r69720: <http://trac.webkit.org/changeset/69720>
Comment 9 WebKit Commit Bot 2010-10-13 17:37:05 PDT
All reviewed patches have been landed.  Closing bug.