0
votes

I am trying to output this custom meta in one of my WordPress page templates. The documentation of the plugin seems to be lacking. ( http://metabox.io/docs/get-meta-value/ )

Because that I have clone as true it is displayed as so in the custom post type

enter image description here

I am trrying to display it VIA html so maybe the output would be something like

<ul>
<li>Red LED footwell lighting</li>
<li>Red LED Trunk Lighting</li>
<li>etc...</li>
</ul>

Here is how I defined the item I am trying to display

        array(
            'name' => 'Interior Mods',
            'desc' => 'List all of the interior mods',
            'id' => $prefix . 'intmods',
            'type' => 'text',
            'std' => '',
            'class' => 'custom-class',
            'clone' => true,
        ),

Thanks

1

1 Answers

1
votes

You can use plug-in codes for get value.

$values =  rwmb_meta(
    'YOUR_PREFIX_text', 
    $args = array(
        'type'=>'text',
        // other options for meta field
    ),
    $post_id = $post->ID
);

if($values){
    echo "<ul>";
    foreach ($values as $key => $value) {
        echo "<li>".$value."</li>";
    }
    echo "</ul>";
}