WordPress.org

Ready to get started?Download WordPress

Forums

Types - Custom Fields and Custom Post Types Management
[resolved] blank custom fields are being added (3 posts)

  1. greeenkaos
    Member
    Posted 11 months ago #

    updated from WP 3.5.1 to WP 3.6 and the Types (custom fields) plugin (http://wordpress.org/plugins/types/) has started creating empty custom field values even when the associated custom fields are not used.

    To be clear, in the 'edit' screen there is a Types section (just below the text editor), no Types fields are added, so in the default 'Custom Fields' section (lower down on the edit screen) there should be no new custom field created, yet for each new post since updating WP to 3.6, there are custom fields created with blank values. Simply deleting the blank custom fields does no good (they reappear). The plugin must be deactivated and the custom fields deleted, but if active, creating a new post will result in blank custom fields again.

    ***
    Update, I thought it was related to 3.6, and reverting to 3.5.1 seemed to fix things, but nope: Now with whatever version of WP the same issue is happening. I'm trying to find a version history of Types to see if downgrading to an older one might help, but am still looking...

  2. greeenkaos
    Member
    Posted 11 months ago #

    OK, so here's the deal. I HAD been using a conventional method for calling meta values:

    $video2 = get_post_meta($post->ID, 'wpcf-video2', false);

    but if I switch to Types code for calling meta values:

    $video2 = types_render_field("video2", array("raw"=>"true"));

    this solves the issue.

  3. Srdjan
    Member
    Plugin Author

    Posted 11 months ago #

    Hi greeenkaos,
    there were changes how custom fields are saved.
    Initially Types saved empty fields, which was cancelled at 1.2 version.
    Later we brought back saving empty fields because of users requests.

    Last version that do not save empty fields is 1.3.1.
    Hope this helps.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.