I’m looking into implementing this right now but can’t seem to get it to stick. It seems to output the normal menu – although the code below is working – just no replacing the titles with the dynamic ttftitle images.
I’m using an ol instead of the usual ul format list but it should be the same? The ttftitles style is called menu fyi.
<ol id="dropmenu">
<?php
$pages = wp_list_pages('sort_column=menu_order&title_li=&exclude=2,6&depth=1');
if ($pages) {
preg_match_all('/<a.*>(.*)<\/a>/', $pages, $array);
$asize = count($array[0]);
for($i = 0; $i < $asize; $i++) {
$link = $array[0][$i];
$title = $array[1][$i];
ob_start();
the_ttftext($array[1][$i], $echo = true, $style="menu", $overrides="");
$ttf = ob_get_clean();
$originalLink = $link;
$link = str_replace(">" . $title, ">" . $ttf, $link);
$pages = str_replace($originalLink, $link, $pages);
}
echo $pages;
}
?>
</ol>
Thoughts? Thanks