Make WordPress Core

Opened 18 years ago

Closed 18 years ago

Last modified 18 years ago

#6898 closed defect (bug) (fixed)

Bad quote escaping in media uploader?

Reported by: Otto42 Owned by:
Priority: normal Milestone: 2.6
Component: General Version: 2.5.1
Severity: normal Keywords:
Cc: Focuses:

Description

Report and fix here:
http://wordpress.org/support/topic/164563/page/2?replies=50#post-737670

Other people report the same issue and that the fix works too.

Short version:
wp-admin/includes/media.php, line 57

$html = "<a href='".attribute_escape($url)."'$rel>$html</a>";

Should be this:

$html = "<a href=\"".attribute_escape($url)."\"$rel>$html</a>";

Because the single quote there can hork up some javascript code that it gets inserted into.

Change History (5)

#1 @ryan
18 years ago

  • Resolutionfixed
  • Status newclosed

(In [7874]) Fix send_to_editor escaping. Props Glotzfisch. fixes #6898 for trunk

#2 @ryan
18 years ago

(In [7875]) Fix send_to_editor escaping. Props Glotzfisch. fixes #6898 for 2.5

#3 @ryan
18 years ago

  • Milestone 2.62.5.2

#4 @ryan
18 years ago

  • Milestone 2.5.22.9

Milestone 2.5.2 deleted

#5 @westi
18 years ago

  • Milestone 2.92.6
Note: See TracTickets for help on using tickets.