I’ve got my settings set to `Category – Post Title` which is what is used on other sites I’ve used/created before but my homepage url is being printed as “[siteurl.com/uncategorized/28/]”.
this page has been indicated as the homepage so it should print the root url although it’s just not.
​
EDIT:
Here’s the PHP code I’m using to output the menu items:
global $post;
$location = ‘menu’;
$nav = wp_get_nav_menu_items( $location );
$output = ‘<ul>’;
$template = file_get_contents( $arttastic->get( ‘theme_dir’ ) . ‘/components/menu/templates/item.html’ );
foreach ( $nav as $item ) {
$icon = $arttastic->get( ‘arttastic_icon_selector’, $item->ID );
$text = $item->title;
$url = get_permalink( $item->ID );
$active = $url === $_SERVER[‘SERVER_URI’]
? ‘active’
: ”;
$replace_pairs = array(
‘{{active}}’ => $active,
‘{{url}}’ => $url,
‘{{text}}’ => $text,
‘{{icon}}’ => $icon[‘value’]
);
$output .= strtr( $template, $replace_pairs );
}
return $output . ‘</ul>’;
​
[ad_2]