WordPress.org

Make WordPress Core

Opened 3 years ago

Closed 2 years ago

Last modified 2 years ago

#21624 closed defect (bug) (fixed)

Multiplle Trackbacks field in edit screen removes spaces btw. URL's on save/update in 3.4 & 3.4.1

Reported by: faddah Owned by: nacin
Milestone: 3.4.2 Priority: normal
Severity: major Version: 3.4
Component: Formatting Keywords: has-patch
Focuses: Cc:

Description (last modified by SergeyBiryukov)

This is reproducable in multiple browsers & OS platforms.

This has happened both in 3.4 & 3.4.1. Was not seen in 3.3x or earlier.

To see original discussion on this issue in WP support forums, see: WP Support Forum - Sending Multiple Trackbacks Problem.

As Ipstenu (Mika Epstein) in the support forums suggested, this may (though not certain about it) be related to previous Trac ticket #17560 (Severe bug in XMLRPC and Windows Live Writer integration related to to_ping), allegedly fixed in last January in Changeset [19675]. It would be helpful to review the support forum link above first and these Trac ticket & Changeset before proceeding on.

Issue — for Trackbacks, to send links back to sites mentioned in-line that are not also Wordpress sites, you fill in the URLs in the Trackbacks field, separating each URL with a space between, as it says to of the Post or Page Edit screen in WP-Core. However, since 3.4 and still in 3.4.1, when you Save Draft, Publish or Update, all the spaces are removed and it becomes one long garbage line of URL's all grouped together. WP then attempts to send out to that, which is garbage, so none of the non-WP sites that are linked-to are ever contacted.

To Reproduce —

In a site running WP 3.4 or 3.4.1 —

  1. Create a new post in WP.
  1. In the post, have links in-line with your verbiage to non-WP sites, say three of them.
  1. In the trackback field in the edit post WP screen, put your three or so non-WP site links, separated by spaces, as it says to right on the screen for that trackback field.
  1. Click on "save draft" or "publish."
  1. Go back and look at at the trackback field.

Expected result —
In WP 3.3.x and earlier versions, it handled the non-WP trackbacks fine and notified those sites of the links in the post or page to it.

Issue —
In WP 3.4 & 3.4.1 still, the spaces between the links in the trackback field are removed on Save Draft, Publish or Update, and the multiple link line becomes one long garbage line and WP attempts to notify that, which, of course does not work.

Again, this is for Trackbacks, to non-WP sites, that are input into the Trackbacks field; not Pingbacks, which are for WP Sites and take the URLs that are in-line in the post and that works just fine.

As mentioned, Ipstenu (Mika Epstein) seems to think this is related to Trac ticket #17560 (Severe bug in XMLRPC and Windows Live Writer integration related to to_ping), and its related Changeset [19675]. I am not quite sure if this is the case or not, but this might at least give a lead on tracking down this problem and why it started happening in WP 3.4 and continues to happen in 3.4.1.

To contact me, faddah, for follow up on this —

faddah wolf
portland, oregon
my_biz@… — e-mail & FaceTime
(503) 449-0531 — iPhone & FaceTime
@yuetsu on twitter
http://ialsowent.com
http://about.me/faddah

Attachments (1)

21624.patch (677 bytes) - added by SergeyBiryukov 3 years ago.

Download all attachments as: .zip

Change History (12)

comment:1 @SergeyBiryukov3 years ago

  • Description modified (diff)

@SergeyBiryukov3 years ago

comment:2 @SergeyBiryukov3 years ago

  • Keywords has-patch added
  • Milestone changed from Awaiting Review to 3.4.2

comment:3 @faddah3 years ago

wow! that was quick. thank you, sergey. parson the nØØb question, but how would i go about testing this patch?

comment:4 @Ipstenu3 years ago

Edit the wp-includes/formatting.php file directly and change the line in red to the one in green.

Or learn SVN diffs, which in this case, may be over kill ;)

comment:5 @faddah3 years ago

yup, that fixed it! adding those brackets & '+' sign where you did in wp-includes/formatting.php keeps the spaces from being deleted in the trackback line on Save Draft, Publish or Update in my version of 3.4.1 (see my site —> http://ialsowent.com/). thank you!

comment:6 @SergeyBiryukov2 years ago

  • Component changed from Editor to Formatting

comment:7 @nacin2 years ago

Unit test: [UT1005]

comment:8 @nacin2 years ago

With PREG_SPLIT_NO_EMPTY, the + isn't needed. Also, the foreach() would also remove any empties even if PREG_SPLIT_NO_EMPTY wasn't specified.

comment:9 @nacin2 years ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In [21718]:

Properly delimit URLs by \r, \n, \t *or* a space in sanitize_trackback_urls(). Fixes multiple trackback URL usage. props SergeyBiryukov, fixes #21624 for trunk.

comment:10 @nacin2 years ago

In [21719]:

Properly delimit URLs by \r, \n, \t *or* a space in sanitize_trackback_urls(). Fixes multiple trackback URL usage. props SergeyBiryukov, fixes #21624 for the 3.4 branch.

comment:11 @nacin2 years ago

[UT1006] passed even before [21718] / [21719].

Note: See TracTickets for help on using tickets.