diff --git a/plugin/includes/common/template-tags.php b/plugin/includes/common/template-tags.php
index 79d0b71..3e297fe 100644
a
|
b
|
function bbp_breadcrumb( $args = array() ) { |
2141 | 2141 | |
2142 | 2142 | // If capable, include a link to edit the tag |
2143 | 2143 | if ( current_user_can( 'manage_topic_tags' ) ) { |
2144 | | $tag_data[] = '<a href="' . bbp_get_topic_tag_edit_link() . '" class="bbp-edit-topic-tag-link">' . __( '(Edit)', 'bbpress' ) . '</a>'; |
| 2144 | $tag_data[] = '<a href="' . bbp_get_topic_tag_edit_link() . '" class="bbp-edit-topic-tag-link" itemprop="url">' . __( '(Edit)', 'bbpress' ) . '</a>'; |
2145 | 2145 | } |
2146 | 2146 | |
2147 | 2147 | // Implode the results of the tag data |
… |
… |
function bbp_breadcrumb( $args = array() ) { |
2162 | 2162 | $r = bbp_parse_args( $args, array( |
2163 | 2163 | |
2164 | 2164 | // HTML |
2165 | | 'before' => '<div class="bbp-breadcrumb"><p>', |
| 2165 | 'before' => '<div class="bbp-breadcrumb" itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><p>', |
2166 | 2166 | 'after' => '</p></div>', |
2167 | 2167 | |
2168 | 2168 | // Separator |
… |
… |
function bbp_breadcrumb( $args = array() ) { |
2186 | 2186 | // Current |
2187 | 2187 | 'include_current' => $pre_include_current, |
2188 | 2188 | 'current_text' => $pre_current_text, |
2189 | | 'current_before' => '<span class="bbp-breadcrumb-current">', |
| 2189 | 'current_before' => '<span class="bbp-breadcrumb-current" itemprop="title">', |
2190 | 2190 | 'current_after' => '</span>', |
2191 | 2191 | ), 'get_breadcrumb' ); |
2192 | 2192 | |
… |
… |
function bbp_breadcrumb( $args = array() ) { |
2199 | 2199 | |
2200 | 2200 | // Do we want to include a link to home? |
2201 | 2201 | if ( !empty( $r['include_home'] ) || empty( $r['home_text'] ) ) { |
2202 | | $crumbs[] = '<a href="' . trailingslashit( home_url() ) . '" class="bbp-breadcrumb-home">' . $r['home_text'] . '</a>'; |
| 2202 | $crumbs[] = '<a href="' . trailingslashit( home_url() ) . '" class="bbp-breadcrumb-home" itemprop="url"><span itemprop="title">' . $r['home_text'] . '</span></a>'; |
2203 | 2203 | } |
2204 | 2204 | |
2205 | 2205 | // Do we want to include a link to the forum root? |
… |
… |
function bbp_breadcrumb( $args = array() ) { |
2216 | 2216 | } |
2217 | 2217 | |
2218 | 2218 | // Add the breadcrumb |
2219 | | $crumbs[] = '<a href="' . $root_url . '" class="bbp-breadcrumb-root">' . $r['root_text'] . '</a>'; |
| 2219 | $crumbs[] = '<a href="' . $root_url . '" class="bbp-breadcrumb-root" itemprop="url"><span itemprop="title">' . $r['root_text'] . '</span></a>'; |
2220 | 2220 | } |
2221 | 2221 | |
2222 | 2222 | // Ancestors exist |
… |
… |
function bbp_breadcrumb( $args = array() ) { |
2237 | 2237 | |
2238 | 2238 | // Forum |
2239 | 2239 | case bbp_get_forum_post_type() : |
2240 | | $crumbs[] = '<a href="' . bbp_get_forum_permalink( $parent->ID ) . '" class="bbp-breadcrumb-forum">' . bbp_get_forum_title( $parent->ID ) . '</a>'; |
| 2240 | $crumbs[] = '<a href="' . bbp_get_forum_permalink( $parent->ID ) . '" class="bbp-breadcrumb-forum" itemprop="url"><span itemprop="title">' . bbp_get_forum_title( $parent->ID ) . '</span></a>'; |
2241 | 2241 | break; |
2242 | 2242 | |
2243 | 2243 | // Topic |
2244 | 2244 | case bbp_get_topic_post_type() : |
2245 | | $crumbs[] = '<a href="' . bbp_get_topic_permalink( $parent->ID ) . '" class="bbp-breadcrumb-topic">' . bbp_get_topic_title( $parent->ID ) . '</a>'; |
| 2245 | $crumbs[] = '<a href="' . bbp_get_topic_permalink( $parent->ID ) . '" class="bbp-breadcrumb-topic" itemprop="url"><span itemprop="title">' . bbp_get_topic_title( $parent->ID ) . '</span></a>'; |
2246 | 2246 | break; |
2247 | 2247 | |
2248 | 2248 | // Reply (Note: not in most themes) |
2249 | 2249 | case bbp_get_reply_post_type() : |
2250 | | $crumbs[] = '<a href="' . bbp_get_reply_permalink( $parent->ID ) . '" class="bbp-breadcrumb-reply">' . bbp_get_reply_title( $parent->ID ) . '</a>'; |
| 2250 | $crumbs[] = '<a href="' . bbp_get_reply_permalink( $parent->ID ) . '" class="bbp-breadcrumb-reply" itemprop="url"><span itemprop="title">' . bbp_get_reply_title( $parent->ID ) . '</span></a>'; |
2251 | 2251 | break; |
2252 | 2252 | |
2253 | 2253 | // WordPress Post/Page/Other |
2254 | 2254 | default : |
2255 | | $crumbs[] = '<a href="' . get_permalink( $parent->ID ) . '" class="bbp-breadcrumb-item">' . get_the_title( $parent->ID ) . '</a>'; |
| 2255 | $crumbs[] = '<a href="' . get_permalink( $parent->ID ) . '" class="bbp-breadcrumb-item" itemprop="url"><span itemprop="title">' . get_the_title( $parent->ID ) . '</span></a>'; |
2256 | 2256 | break; |
2257 | 2257 | } |
2258 | 2258 | } |
2259 | 2259 | |
2260 | 2260 | // Edit topic tag |
2261 | 2261 | } elseif ( bbp_is_topic_tag_edit() ) { |
2262 | | $crumbs[] = '<a href="' . get_term_link( bbp_get_topic_tag_id(), bbp_get_topic_tag_tax_id() ) . '" class="bbp-breadcrumb-topic-tag">' . sprintf( __( 'Topic Tag: %s', 'bbpress' ), bbp_get_topic_tag_name() ) . '</a>'; |
| 2262 | $crumbs[] = '<a href="' . get_term_link( bbp_get_topic_tag_id(), bbp_get_topic_tag_tax_id() ) . '" class="bbp-breadcrumb-topic-tag" itemprop="url"><span itemprop="title">' . sprintf( __( 'Topic Tag: %s', 'bbpress' ), bbp_get_topic_tag_name() ) . '</span></a>'; |
2263 | 2263 | |
2264 | 2264 | // Search |
2265 | 2265 | } elseif ( bbp_is_search() && bbp_get_search_terms() ) { |
2266 | | $crumbs[] = '<a href="' . home_url( bbp_get_search_slug() ) . '" class="bbp-breadcrumb-search">' . __( 'Search', 'bbpress' ) . '</a>'; |
| 2266 | $crumbs[] = '<a href="' . home_url( bbp_get_search_slug() ) . '" class="bbp-breadcrumb-search" itemprop="url"><span itemprop="title">' . __( 'Search', 'bbpress' ) . '</span></a>'; |
2267 | 2267 | } |
2268 | 2268 | |
2269 | 2269 | /** Current ***********************************************************/ |