Support » Fixing WordPress » Custom fields in 3.4.2

  • Resolved pwnst



    I updated to 3.4.2 few hours ago and I cant get my custom fields in posts to work. Every time I try to add a new custom field nothing happens. I got no problem in earlier versions.

    – I got no addons/plugins and I’ve tried without my functions.php.

    – I get the same result with Opera and Chrome.


Viewing 15 replies - 1 through 15 (of 18 total)
  • Yeah .. Same here. I use 4 custom fields in my posts. Earlier I used to add values for those 4 custom fields one after the other. But after upgrading, I add one custom field, hit ADD CUSTOM FIELD button and the button disappears. I have to hit “Save as draft” and the custom fields button re-appears. For 4 custom fields, I have to do the Save As Draft thing 4 times. Then I can publish the post. Although it works but then I look at 4 post revisions that were created because of saving over and again.

    Someone suggested to download the WordPress package and then Overwrite the WP-Admin and WP-Includes folders on your server taken from the package. I’m gonna try that and see if that works. Will let you know if it worked.

    I am getting this too.

    This is DEFINITELY a bug.

    Sometimes when clicking Add Custom Field The button sometimes disappears momentarily, turns yellow, and reappears in the box above…

    And sometimes when clicking Add Custom Field the button disappears and gets replaced with some line about custom fields in your theme.

    When will this bug be fixed? It’s crippling my job atm 🙁

    Hey Guys,

    There is a known bug in 3.4.2 with custom fields and the add / update buttons. To fix this you will need to install the hot fix plugin.

    Hey Chris,

    I understand that hotfix plugin may fix this problem but I do not consider that a good solution. Not everyone loves putting up a pile of plugins in their WordPress installation. I hate keeping too many plugins and I try to keep minimum plugins.
    A better solution would have been a DIY article. I will fix this problem, suggest it to WordPress folks (if someone hasn’t already) and also write and publish a DIY article.
    THAT would be a better solution.

    Thanks for the help anyway.

    Yeah Ryan, that little freakin button is playing nuts lol. It is running around all over the place 😀

    Add this code snippet to your functions.php file to fix the custom fields bug in 3.4.2:

    function fix_custom_fields_in_wp342() {
    	global $wp_version, $hook_suffix;
    	if ( '3.4.2' == $wp_version && in_array( $hook_suffix, array( 'post.php', 'post-new.php' ) ) ) : ?>
    <script type="text/javascript">
    jQuery(document).delegate( '#addmetasub, #updatemeta', 'hover focus', function() {
    	jQuery(this).attr('id', 'meta-add-submit');
    add_action( 'admin_print_footer_scripts', 'fix_custom_fields_in_wp342' );


    but new custom field is not add the fields list.

    show post and reedit post.

    then new custom field display custom fields list.

    Thank you.

    Thread Starter pwnst



    Thanks for the solution Chris. Works for me at least. =)

    Chris, your code works here too.


    CHris that code is making template files all code cleaned up when updated.

    Thanks Chris, your help is greatly appreciated! Had the same problem, both your solutions worked for me!

    Nicely done Chris, thanks for the code snippet. Works like a charm.

    Neither the hotfix or the snippet posted here works for me. No customs fields showing on my wp 3.4.2. Suggestions?

    My bad. I’m not worthy. Egg all over my face.

    I´ve totally missed the panel settings. Everything works A-OK now after I acivated the custom fields in the panel settings.

    This just shows how used I got to my old WP-rig…

    Thank you @chris Olbekson, it done for me and i have fixed for all my website. Thank you again!

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘Custom fields in 3.4.2’ is closed to new replies.