parent
600b561fd9
commit
bd11f51d04
|
@ -221,7 +221,6 @@ class WC_Breadcrumb {
|
|||
$_name = $product_post_type->labels->singular_name;
|
||||
}
|
||||
|
||||
$this->prepend_shop_page();
|
||||
$this->add_crumb( $_name, get_post_type_archive_link( 'product' ) );
|
||||
}
|
||||
|
||||
|
|
|
@ -1198,7 +1198,7 @@ if ( ! function_exists( 'woocommerce_breadcrumb' ) ) {
|
|||
*/
|
||||
function woocommerce_breadcrumb( $args = array() ) {
|
||||
$args = wp_parse_args( $args, apply_filters( 'woocommerce_breadcrumb_defaults', array(
|
||||
'delimiter' => ' / ',
|
||||
'delimiter' => ' / ',
|
||||
'wrap_before' => '<nav class="woocommerce-breadcrumb" ' . ( is_single() ? 'itemprop="breadcrumb"' : '' ) . '>',
|
||||
'wrap_after' => '</nav>',
|
||||
'before' => '',
|
||||
|
|
|
@ -149,6 +149,7 @@ Yes you can! Join in on our [GitHub repository](http://github.com/woothemes/wooc
|
|||
* Fix - Stock status when updating out of stock product.
|
||||
* Fix - Fix place order button text on init.
|
||||
* Fix - When duplicating products, handle entities.
|
||||
* Fix - Double shop page in breadcrumb and white space issues.
|
||||
* Tweak - Added DOMDocument item in the System Status as a requirement.
|
||||
* Tweak - Simplify default mode should be 'standard'.
|
||||
* Tweak - Set attribte 'query_var' true when public.
|
||||
|
|
|
@ -11,30 +11,29 @@
|
|||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ( $breadcrumb ) : ?>
|
||||
if ( $breadcrumb ) {
|
||||
|
||||
<?php echo $wrap_before; ?>
|
||||
echo $wrap_before;
|
||||
|
||||
<?php foreach ( $breadcrumb as $key => $crumb ) : ?>
|
||||
foreach ( $breadcrumb as $key => $crumb ) {
|
||||
|
||||
<?php echo $before; ?>
|
||||
echo $before;
|
||||
|
||||
<?php if ( ! empty( $crumb[1] ) && sizeof( $breadcrumb ) !== $key + 1 ) : ?>
|
||||
<?php echo '<a href="' . esc_url( $crumb[1] ) . '">' . esc_html( $crumb[0] ) . '</a>'; ?>
|
||||
<?php else : ?>
|
||||
<?php echo esc_html( $crumb[0] ); ?>
|
||||
<?php endif; ?>
|
||||
if ( ! empty( $crumb[1] ) && sizeof( $breadcrumb ) !== $key + 1 ) {
|
||||
echo '<a href="' . esc_url( $crumb[1] ) . '">' . esc_html( $crumb[0] ) . '</a>';
|
||||
} else {
|
||||
echo esc_html( $crumb[0] );
|
||||
}
|
||||
|
||||
<?php echo $after; ?>
|
||||
echo $after;
|
||||
|
||||
<?php if ( sizeof( $breadcrumb ) !== $key + 1 ) : ?>
|
||||
<?php echo $delimiter; ?>
|
||||
<?php endif; ?>
|
||||
if ( sizeof( $breadcrumb ) !== $key + 1 ) {
|
||||
echo $delimiter;
|
||||
}
|
||||
|
||||
<?php endforeach; ?>
|
||||
}
|
||||
|
||||
<?php echo $wrap_after; ?>
|
||||
echo $wrap_after;
|
||||
|
||||
<?php endif; ?>
|
||||
}
|
Loading…
Reference in New Issue