[wpmu-trac] [WordPress MU Trac] #1134: Logic Error in Object Tag Parsing
WordPress MU Trac
wpmu-trac at lists.automattic.com
Mon Oct 19 23:59:32 UTC 2009
#1134: Logic Error in Object Tag Parsing
------------------------+---------------------------------------------------
Reporter: jpatterson | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone:
Component: component1 | Version:
Severity: normal | Keywords: HTML Parsing Object Embedded Video
------------------------+---------------------------------------------------
I have found a logic error in the WYSIWYG to edit posts/pages with regard
to the cleaning/parsing of HTML object tags. The error occurs in the
handshake between the WYSIWYG javascript and the PHP as follows: I enter
my HTML code for the video that I want to embed using the "HTML" view.
Then when I switch to the "Visual" view, the WYSIWYG strips my code out
and replaces it with it's own code. That's fine and dandy, however, when I
save the post/page the PHP strips out some of the code that the WYSIWYG
inserted, which make so that the embedded video doesn't work in Internet
Explorer. This can be fixed by either preventing the WYSIWYG from
cleaning/parsing the original code, or in preventing the PHP from
stripping out the WYSIWYG code (probably the latter is the better
solution). Specifically the PHP strips out the "clsid:" from the "classid"
attribute in the object tag. I am attaching a text file with HTML snippets
of the code I enter, the code the WYSIWYG cleans/parses, and the code that
the PHP saves to the database. I have found a quick fix (not very elegant
at all) by simply using a str_replace to re-insert (this can be done in
the theme, or in the wp-includes/post-template.php file) the "clsid:"
where necessary.
--
Ticket URL: <http://trac.mu.wordpress.org/ticket/1134>
WordPress MU Trac <http://mu.wordpress.org/>
WordPress Multiuser
More information about the wpmu-trac
mailing list