I have some custom fields added via a meta box, and I'd like to output them into a dl on the post itself, with the field being the term and the data it contains being the term. Currently, calling <?php the_meta(); ?>
outputs an unordered list.
Example:
<dl>
<dt>Date</dt><dd>Monday 26 March 2012</dd>
<dt>Time</dt><dd>11pm</dd>
</dl>
I have the meta box fully implemented, it's just the output that I'm clueless with. The relevant part of the meta box code, should it help:
function admin_init(){
add_meta_box("events_meta", "Event Details", "event_details", "post", "normal", "default");
}
function event_details() {
global $post;
$custom = get_post_custom($post->ID);
$date = $custom["date"][0];
$time = $custom["time"][0];
$location = $custom["location"][0];
$tickets = $custom["tickets"][0];
?>
<p><label>Date:</label><br />
<textarea cols="34" rows="2" name="date"><?php echo $date; ?></textarea></p>
<p><label>Time:</label><br />
<textarea cols="34" rows="2" name="time"><?php echo $time; ?></textarea></p>
<p><label>Location:</label><br />
<textarea cols="34" rows="2" name="location"><?php echo $location; ?></textarea></p>
<p><label>Ticket Price(s):</label><br />
<textarea cols="34" rows="2" name="tickets"><?php echo $tickets; ?></textarea></p>
<?php
}
Thanks in advance for any help! :)