function notes_column_content($name) { global $post, $ppn_db_notes, $wpdb; switch ($name) { case 'ppn_notes': $latest_note = $wpdb->get_row('SELECT noteid, notecontent, author, notetime FROM ' . $ppn_db_notes . ' WHERE postid = ' . $post->ID . ' ORDER BY notetime DESC LIMIT 1', OBJECT); if ($latest_note) { $author_name = ppnFunctionCollection::get_author_name($latest_note->author); print '[<em>' . date(__('M j, Y \\a\\t G:i', 'peters_post_notes'), strtotime($latest_note->notetime)) . ', ' . $author_name . '</em>]<br />' . $latest_note->notecontent; } else { print '-'; } } }