Make WordPress Core

Opened 18 years ago

Closed 17 years ago

Last modified 17 years ago

#2316 closed defect (bug) (fixed)

Custom Fields disappearing and "_encloseme" and "_pingme" entries in the database over and over

Reported by: cnc137's profile cnc137 Owned by:
Milestone: 2.3 Priority: normal
Severity: normal Version: 2.0.5
Component: Administration Keywords: custom fields encloseme pingme disappear hidden has-patch
Focuses: Cc:


Myself and other have noticed after installing WordPress 2.0 that there are "_encloseme" and "_pingme" entries in the "wp_postmeta" database table over and over with "meta_value" set to "1". I upgraded from WordPress 1.5.2 to 2.0 if this helps diagnose the problem.

The problem is related to the custom field section on the "Write Post" page. I also noticed that some of my custom fields do not display in the custom fields section even though I can add them via the form generate by rc:custom_field_gui plugin. I tried adding these custom fields with the plugin turned on and off and both ways didn't work even though the form allows them to be added.

View this support topic for more details:

Thank you for looking into this.



Attachments (3)

2316.diff (475 bytes) - added by tenpura 18 years ago.
Hide "_xxx" stuff from the dropdown. Increase the LIMIT value a bit.
2316b.diff (426 bytes) - added by Nazgul 17 years ago.
2316c.diff (396 bytes) - added by markjaquith 17 years ago.

Download all attachments as: .zip

Change History (20)

#1 @ryan
18 years ago

Regarding _pingme and _encloseme, custom fields preceded by an underscore are used internally by WP and are hidden from view in the "Custom Fields" form.

#2 @cnc137
18 years ago

If I go to my Custom Fields area and click the drop-down box on the "Write Post" page I can see them there along with all my other custom fields I have created except for one custom field entry that is missing but works using the rc:custom_field_gui plugin.

It seems like "_encloseme" and "_pingme" custom fields keep getting set to "1" over and over everytime I edit a post. I only have 15 total posts and I have been editing them a lot because I have been making changes and testing our WordPress 2.0 setup before we go live with it. I already have 259 rows in my "wp_postmeta" table and 243 of them are entries for "_encloseme" and "_pingme" that I did not make.


#3 @ryan
18 years ago

Yes, they'll show in the dropdown. We should probably filter there too.

2.0 didn't always clean up the _pingme and _encloseme fields. This will be fixed in 2.0.1, but the extra fields don't really cause a problem aside from being a little wasteful.


#4 @cnc137
18 years ago

  • Keywords disappear hidden added
  • Summary changed from "_encloseme" and "_pingme" entries in the database over and over to Custom Fields disappearing and "_encloseme" and "_pingme" entries in the database over and over

My custom fields still seem to be disappearing randomly from the drop-down list. I magically no longer see the "_encloseme" and "_pingme" custom fields in the drop-down list, but others are missing or hidden now too.

I have the following custom fields and others that I have created and used under multiple topics on my WordPress site:

Screenshot 1, Screenshot 2, Screenshot 3, Screenshot 4, Screenshot 5

... but I only see the following in this order in my drop-down list on the "Write Post" page now:

Screenshot 1, Screenshot 5, Screenshot 4

Why would the "Screenshot 2" and "Screenshot 3" custom field I created and used under multiple entries all of a sudden disappear from the drop-down list? Is this a bug? Are they being hidden along with "_encloseme" and "_pingme" now?

It looks like some thing is goofy with the custom fields in WordPress 2.0 at least on my site. The previous entries that include "Screenshot 2" and "Screenshot 3" are still in the database and working on the site, but I can't add "Screenshot 2" or "Screenshot 3" to any new posts because they are not available in the drop-down list. I also can't make new custom fields for these because they already exist in the database.

If you need any more info from me let me know and I hope this gets addressed in WordPress 2.0.1, since the custom field entries are a vital part of my site.


#5 @markjaquith
18 years ago

  • Keywords bg|reporter-feedback added

Still have the problem with 2.0.1? Make sure to deactivate the custom files gui plugin before testing!

#6 @cnc137
18 years ago

I have now upgraded from WP 2.0 to WP 2.0.1 and am still having these problems.

I fixed the disappearing custom fields by using the patch mentioned in this ticket:

Ticket #1865
Admin custom field key dropdown has hardcoded limit of 10

Is this patch going to be incorporated in the next version of WordPress and why wouldn't we be able to add more than 10 custom fields?


I am still seeing the the "_encloseme" and "_pingme" in the drop down list even with the "rc:custom_field_gui" plugin turned off.


I am still seeing a "_encloseme" and "_pingme" entries in the "wp_postmeta" database table everytime I make a new post or edit one with the "rc:custom_field_gui" plugin turned on or off. I still have only have 15 posts on my testing site, but I have 361 "wp_postmeta" table entries and 294 of them are the "_encloseme" and "_pingme" entries over and over again.

Hopefully this will be fixed in WP 2.0.2 or 2.1?


#7 @matt
18 years ago

"Ticket #1865 Admin custom field key dropdown has hardcoded limit of 10"

Chill, you can have unlimited custom fields, that ticket is just about which keys appear in the drop down. (The 10 most recent.)

#8 @davidhouse
18 years ago

Can no-one else verify this? Try creating a vanilla testblog on the same server setup as the one where it's broken, and see if it's still broken.

#9 @foolswisdom
18 years ago

In , people have continued to report this problem. Is there any insights in that thread? What information will help understand the problem?

18 years ago

Hide "_xxx" stuff from the dropdown. Increase the LIMIT value a bit.

#10 @tenpura
18 years ago

  • Keywords has-patch added

#11 @tenpura
18 years ago

  • Milestone set to 2.1
  • Version changed from 2.0 to 2.0.5

#12 @matt
18 years ago

  • Milestone 2.1 deleted

17 years ago

#13 @Nazgul
17 years ago

  • Keywords bg|reporter-feedback removed
  • Milestone set to 2.3 (trunk)

Patch hides internal custom fields from the Custom Fields drop-down box on the "Write Post" page.

17 years ago

#14 @markjaquith
17 years ago

Why don't we just exclude them from the query? Otherwise, we could end up with an empty dropdown box (if all the returned keys have an underscore prefix). See 2316c.diff

#15 @rob1n
17 years ago

I like patch C. Makes life easier.

#16 @markjaquith
17 years ago

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

(In [5691]) Omit underscore-prefixed meta keys from dropdown list. fixes #2316

#17 @markjaquith
17 years ago

(In [5692]) Correct SQL query in [5691]. fixes #2316

Note: See TracTickets for help on using tickets.