#11603 closed enhancement (wontfix)
Ensure that oEmbed returns XHTML valid code
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.9 |
Component: | Validation | Keywords: | dev-feedback 2nd-opinion |
Focuses: | Cc: |
Description
Works well but no XHTML valid auto video support. Please make it xhtml valid. :)
Attachments (1)
Change History (16)
#2
in reply to:
↑ 1
@
15 years ago
Replying to miqrogroove:
hpguru, your bug report needs to contain a description of the problem. What isn't valid? How can we reproduce the problem on our own blogs?
I add a screenshot.
#3
@
15 years ago
"Easier video embeds that allow you to just paste a URL on its own line and have it magically turn it into the proper embed code, with Oembed support for YouTube, Daily Motion, Blip.tv, Flickr, Hulu, Viddler, Qik, Revision3, Scribd, Google Video, Photobucket, PollDaddy, and WordPress.tv (and more in the next release)."
Broken my site XHTML with 7 errors.
#4
@
15 years ago
So that screenshot shows the code you embedded from youtube.com. What would you like WordPress to do differently?
#5
@
15 years ago
- Component changed from General to Validation
- Keywords reporter-feedback removed
- Milestone changed from 2.9.1 to 3.0
- Priority changed from high to normal
- Type changed from defect (bug) to enhancement
he's complaining that the code returned by YouTube isn't XHTML valid. suggesting wontfix.
@hpguru: please complain to YouTube, and ask them to add a wmode=transparent parameter while they're at it.
#6
@
15 years ago
- Summary changed from New automated video support to Ensure that oEmbed returns XHTML valid code
#7
follow-up:
↓ 9
@
15 years ago
suggesting wontfix.
I can imagine the next ticket, "Please block embedded advertising / cookies / videos that have been deleted / what have you."
#8
@
15 years ago
WordPress has WPvideo plugin that add valid YouTube videos. I think that is possible in WP own oEmbed. But i like how oEmbed work. Looks great that options are xhtml valid in 3.0 WP.
#9
in reply to:
↑ 7
@
15 years ago
Replying to miqrogroove:
suggesting wontfix.
I can imagine the next ticket, "Please block embedded advertising / cookies / videos that have been deleted / what have you."
No. I think that XHTML valid code is WordPress PROMISE. Wordpress is XHTML VALID. So, i think that oEmbed feature would be a valid to, is what software to use permit. :)
#11
@
15 years ago
If you want valid XHTML then don't use oEmbed. C'mon. The entire premise of this feature is to allow 3rd-parties to XSS your website. If it's not YouTube causing the problem it will be any of the other whitelisted providers eventually.
#12
@
15 years ago
- Keywords needs-patch added; oEmbed removed
The issue at heart here, Is that your doctype does not allow the usage of <embed>
which is required for older non-XHTML compliant browsers.
In an environment where you're using XHTML, you'll probably need to filter out the non-compliant elements, as oEmbed is designed to use the trusted code from the embedder. And its unlikely WordPress is going to mess with the results, because removing embed
means removing support for older browsers (No idea which browsers..)
In your case, something like this (untested) will achieve it:
add_filter('oembed_dataparse', '_strip_embed'); function _strip_embed($data) { $data = preg_replace('|<embed.+?>.*?</embed>|i', '', $data); return $data; }
hpguru, your bug report needs to contain a description of the problem. What isn't valid? How can we reproduce the problem on our own blogs?