WordPress display hidden custom fields

WordPress won’t show keys starting with an “_” (underscore) in the custom fields list. If you want to display those hidden custom fields you can simply display them in wp-admin add/edit post or page section by simply adding following code inside your themes functions.php file.

Just open functions.php file from your current activate theme in text editor and add following code inside that.

add_action( 'admin_head', 'show_hidden_customfields' );
function show_hidden_customfields() {
    echo "<style type='text/css'>#postcustom .hidden { display: table-row; }</style>\n";
}

make sure to add this code inside a PHP tag .

Leave a Reply

Your email address will not be published. Required fields are marked *

One Comment

  1. Pingback: Elektrische Zahnbuerste