パンくずが縦になる
-
パンくずをプラグインなしで入れています。
しかしホーム>カテゴリ>記事
と並べたいのですが、何故か
ホーム
カテゴリ>記事と並んでしまいます。
<?php
function get_breadcrumbs(){
global $wp_query;if ( !is_home() ){
// Start the UL
echo ‘- ‘;
- ‘. HOME .’
// Add the Home link
echo ‘‘;
if ( is_category() )
{
$catTitle = single_cat_title( “”, false );
$cat = get_cat_ID( $catTitle );
echo ”- » “. get_category_parents( $cat, TRUE, ” » ” ) .”
- » Archives
- » Search Results
- » 404 Not Found
- » ‘. get_category_parents( $category_id, TRUE, ” » ” );
echo the_title(”,”, FALSE) .” - » “.the_title(”,”, FALSE).”
- » ‘. strip_tags( apply_filters( ‘single_post_title’, get_the_title( $ancestor ) ) ) .’
- » ‘. strip_tags( apply_filters( ‘single_post_title’, get_the_title( $ancestor ) ) ) .’
“;
}
elseif ( is_archive() && !is_category() )
{
echo ”“;
}
elseif ( is_search() ) {echo ”
“;
}
elseif ( is_404() )
{
echo ”“;
}
elseif ( is_single() )
{
$category = get_the_category();
$category_id = get_cat_ID( $category[0]->cat_name );echo ‘
“;
}
elseif ( is_page() )
{
$post = $wp_query->get_queried_object();if ( $post->post_parent == 0 ){
echo ”
“;
} else {
$title = the_title(”,”, FALSE);
$ancestors = array_reverse( get_post_ancestors( $post->ID ) );
array_push($ancestors, $post->ID);foreach ( $ancestors as $ancestor ){
if( $ancestor != end($ancestors) ){
echo ‘‘;
} else {
echo ‘‘;
}
}
}
}// End the UL
echo “
“;
}
}
?>とfunctions.phpに記入しています。
どこを直したら横1列になるのでしょうか。
CSSで指定してみましたが出来ませんでした。宜しくお願い致します。
- トピック「パンくずが縦になる」には新たに返信することはできません。