Make WordPress Core

Opened 14 years ago

Closed 14 years ago

#11569 closed enhancement (fixed)

Media.php validation fix

Reported by: simek's profile Simek Owned by:
Milestone: 3.0 Priority: normal
Severity: minor Version: 2.9
Component: Validation Keywords: has-patch
Focuses: Cc:

Description (last modified by azaozz)

Remove unneeded empty span from the uploader and the Media Library screen.

Attachments (3)

media.php.validation.fix.patch (1.2 KB) - added by Simek 14 years ago.
media.php.validation.fix.v2.patch (2.6 KB) - added by Simek 14 years ago.
additional validation fix - missing FORM close tag added
11569.patch (1.4 KB) - added by hakre 14 years ago.

Download all attachments as: .zip

Change History (13)

#1 follow-up: @miqrogroove
14 years ago

  • Keywords reporter-feedback added; has-patch tested removed

Empty span tags do not cause validation errors. This ticket should be closed invalid unless a proper description is added.

@Simek
14 years ago

additional validation fix - missing FORM close tag added

#2 in reply to: ↑ 1 @Simek
14 years ago

Replying to miqrogroove:
You have right - W3C Validator do not treat it like error but IMO avoiding empty spans is a good habit.

Additional in new patch - missing FORM close tag added.

#3 follow-up: @miqrogroove
14 years ago

  • Milestone 2.9.1 deleted
  • Resolution set to invalid
  • Status changed from new to closed

No Bug Description

Simek, you can't just throw patches at the developers and expect them to psychically understand why you want them to make changes. If there is a bug here you need to describe what the problem is, where you found it, and how someone else might find the same problem.

#4 @azaozz
14 years ago

  • Description modified (diff)
  • Keywords reporter-feedback removed
  • Milestone set to 3.0
  • Resolution invalid deleted
  • Status changed from closed to reopened

#5 in reply to: ↑ 3 @azaozz
14 years ago

Replying to miqrogroove:

No Bug Description

Not everybody's first language is English. I can understand that it's easier to write code than descriptions. In this case the patch is pretty much self-explanatory.

#6 @miqrogroove
14 years ago

  • Severity changed from trivial to minor
  • Version changed from 2.9 to 2.5

After all the posts by staff complaining about tickets with a lack of information, I thought it would be helpful to close the bare patches. Once again I'm proven wrong and will let you guys fight amongst yourselves.

Here is the description I was working on to reopen the ticket:

If you look at the Upload/Insert buttons for attaching media to a new post, you can copy those links and hit them directly to grab code for validation. An example path looks like /wp-admin/media-upload.php?post_id=-1261613461&type=image&TB_iframe=true

At such URLs there is a full entity returned with (mostly valid) XHTML doctype. However, each entity contains one FORM element that is not closed, and does cause a validation error.

This was probably introduced at http://core.trac.wordpress.org/browser/trunk/wp-admin/includes/media.php?rev=7092

I am not aware of any bug or cosmetic problem caused by the missing close tag.

Enjoy.

#7 @hakre
14 years ago

  • Keywords has-patch added

Patch did not apply clean any longer. I updated it to relfect the two named changes, ignored the whitespace changes.

@hakre
14 years ago

#8 @hakre
14 years ago

  • Priority changed from low to normal

#9 @hakre
14 years ago

  • Version changed from 2.5 to 2.9

#10 @azaozz
14 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [12582]) Remove unneeded empty span and add form closing tag in media.php, props Simek and hakre, fixes #11569

Note: See TracTickets for help on using tickets.