Support » Plugins » Hacks » convert 0 into meta_key – custom field

  • Hello guys,

    I have a product page, where i wants to display custom fields in tabular format. I inserted below code in single.php to get my custom fields for the same.

    echo '<table id="cf">';
       $mykey_values = get_post_custom_values('my_key');
      foreach ( $mykey_values as $key => $value ) {
       echo '<tr>';
        echo "<td>$key  </td><td> $value<br /></td>";
       echo '</tr>';
    echo '</table>';

    The result was good but not great as the meta key was displaying 0 , 1, 2 etc. like array. check the link for reference.

    Now i just want a code which will change this values (0,1) to my custom field’s meta key, which i will entered.

    plz guys help me.


  • The topic ‘convert 0 into meta_key – custom field’ is closed to new replies.