Ticket #5088 (closed defect: fixed)

Opened 1 year ago

Last modified 1 year ago

Visual Editor Disabled, Editing a Page With HTML Encoded Entities &lt;span&gt; changes them into <> changing the content

Reported by: foolswisdom Assigned to: anonymous
Priority: highest omg bbq Milestone: 2.3.1
Component: Administration Version: 2.3
Severity: critical Keywords: needs-patch
Cc: bobg@emphatic.com

Description (Last modified by foolswisdom)

Editing a Page With HTML Encoded Entities &lt;span&gt; changes them into <> changing the content

ENV: WP trunk (2.3+r6172)
User Profile > Uncheck (DISABLE) Use the visual editor when writing

Repro: Always
Steps:
1. Create a page with Page Content of
&lt;span&gt;
2. Publish the page
3. Edit the page again

ACTUALLY RESULT:
The Page Content is now
<span>

EXPECTED RESULT:
The Page Content should still be
&lt;span&gt;

Change History

09/27/07 02:11:06 changed by foolswisdom

  • description changed.

09/27/07 02:12:22 changed by foolswisdom

  • keywords set to noTinyMCE.
  • summary changed from Editing a Page With HTML Encoded Entities &lt;span&gt; changes them into <> changing the content to Visual Editor Disabled, Editing a Page With HTML Encoded Entities &lt;span&gt; changes them into <> changing the content.

09/27/07 02:36:40 changed by bglickstein

As I described in my original report, issue #5084, this also happens in the other direction: non-encoded HTML entities become encoded.

09/27/07 02:43:32 changed by bglickstein

  • cc set to bobg@emphatic.com.

09/27/07 02:47:03 changed by foolswisdom

bglickstein, please try to isolate the "other direction" issue you are encountering and write a bug report with repro steps. Posts not pages? Can you only repro it with posts made from XML-RPC? What blog client are you using?

09/27/07 05:31:27 changed by Viper007Bond

I'm unable to reproduce this using latest SVN. I did exactly as the original ticket described and I got the exact code I originally entered after editing the post.

09/27/07 05:34:31 changed by Viper007Bond

Er, I misread. It works fine for posts, it is indeed broken for pages.

09/27/07 05:35:08 changed by Viper007Bond

  • keywords changed from noTinyMCE to needs-patch.
  • priority changed from high to highest omg bbq.
  • component changed from General to Administration.

09/27/07 08:04:39 changed by johnbillion

bglickstein, can you verify this bug still exists with all your plugins disabled?

09/27/07 08:37:42 changed by cosmix

This seems to be a core bug. It is always reproducible without any active plugins on 2.3. I managed to get this working by adding the format_to_edit() and apply_filters() lines taken from the same function on 2.2.3 to the get_post_to_edit() found in wp-admin/includes/post.php at line 162 on WP2.3. Since I am not familiar with the design of WP and the changes that took place between 2.2.3 and 2.3 this might be a very wrong way of fixing this; this is why I am not attaching a patch here. In any case, I hope it helps someone to find a better solution.

09/28/07 15:39:20 changed by cosmix

Note that the suggested 'fix' above breaks posts.

10/12/07 16:34:49 changed by raptorNL

Problem seems to be fixed in the latest development revision (6226).

10/12/07 22:21:38 changed by ryan

I think [6184] fixed this. Should be fixed in trunk and the 2.3 branch.

10/15/07 20:47:34 changed by ryan

  • status changed from new to closed.
  • resolution set to fixed.

Resolving as fixed. If you can reproduce this using the latest from the 2.3 branch, please re-open.