How can I hook the wp_list_pages function so that it reads a value of a custom field and displays it instead of displaying the page title?
3 Answers
A quick Google Search came up with this
Source
Try the following:
function wp_list_pages_filter($output) {
// modify $output here, it's a string of <li>'s by the looks of source
return $output;
}
add_filter('wp_list_pages', 'wp_list_pages_filter');