{"id":1289,"date":"2023-10-27T09:44:10","date_gmt":"2023-10-27T09:44:10","guid":{"rendered":"https:\/\/wpshortcode.org\/?p=1289"},"modified":"2023-10-27T09:44:11","modified_gmt":"2023-10-27T09:44:11","slug":"flexy-breadcrumb","status":"publish","type":"post","link":"https:\/\/wpshortcode.org\/flexy-breadcrumb\/","title":{"rendered":"Flexy Breadcrumb Shortcode"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Below, you&#8217;ll find a detailed guide on how to add the <strong>Flexy Breadcrumb Shortcode<\/strong> to your WordPress website, including its <strong>parameters<\/strong>, <strong>examples<\/strong>, and <strong>PHP function code<\/strong>. Additionally, we&#8217;ll assist you with common issues that might cause the Flexy Breadcrumb Plugin shortcode not to show or not to work correctly.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Before starting, here is an overview of the Flexy Breadcrumb Plugin and the shortcodes it provides:<\/p>\n\n\n<p>    <div class=\"plugin-info-box\">\n        <div class=\"top-main\">\n            <!-- SVG Image -->\n            <div class=\"plugin-image\">\n                <img decoding=\"async\" src=\"https:\/\/ps.w.org\/flexy-breadcrumb\/assets\/icon-128x128.png?rev=1839281\" alt=\"Plugin Icon\" \/>\n            <\/div>\n            \n            <div class=\"plugin-descriptive-part\">\n                <!-- Plugin Name with Link -->\n\n                    <a class=\"plugin-title\" href=\"https:\/\/wordpress.org\/plugins\/flexy-breadcrumb\" target=\"_blank\" rel=\"noopener\">\n                        Flexy Breadcrumb                    <\/a>\n\n\n                <!-- Plugin Description -->\n                <p class=\"plugin-description\">\n                    &quot;Flexy Breadcrumb is a user-friendly WordPress plugin that enhances website navigation by providing a customizable and interactive breadcrumb trail. It&#039;s perfect for improving user experience.&quot;                <\/p>\n            <\/div>\n        <\/div>\n\n        <!-- Rating and Additional Info -->\n        <div class=\"plugin-meta\">\n            <span class=\"plugin-rating\">\n                <span class='stars'>\u2605\u2605\u2605\u2605\u2606<\/span> (19)\n            <\/span>\n            <span class=\"plugin-active-installs\">\n                <strong>Active Installs<\/strong>: 20000+\n            <\/span>\n            <span class=\"plugin-tested\">\n                <strong>Tested with<\/strong>: 6.3.2            <\/span>\n            <span class=\"plugin-php-version\">\n                <strong>PHP Version<\/strong>: 7.2            <\/span>\n        <\/div>\n\n        <!-- List of Included Shortcodes -->\n        <div class=\"plugin-shortcodes\">\n            <strong>Included Shortcodes:<\/strong>\n            <ul>\n                <li>[flexy_breadcrumb]<\/li>            <\/ul>\n        <\/div>\n    <\/div>\n    <\/p>\n\n\n\n<div style=\"height:50px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Flexy Breadcrumb [flexy_breadcrumb] Shortcode<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The Flexy Breadcrumb shortcode allows you to display a breadcrumb navigation on your WordPress site. It dynamically generates the breadcrumb trail based on the current page, post, or category. \n\n \n\nThis shortcode supports various pages such as WooCommerce Shop Page, Custom Post Type Listing, Archive Pages, Tag Page, and more. It also supports different archive pages like daily, monthly, and yearly archives.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode<\/strong>: <code>[flexy_breadcrumb]<\/code><\/p>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Examples and Usage<\/h3>\n\n\n<p><strong>Basic example<\/strong> &#8211; Show the breadcrumb trail on your page.<\/p>\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">[flexy_breadcrumb]<\/code><\/pre>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">PHP Function Code<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">In case you have difficulties debugging what causing issues with <code>[flexy_breadcrumb]<\/code> shortcode, check below the related PHP functions code.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode line<\/strong>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">add_shortcode( 'flexy_breadcrumb', array( $this, 'flexy_breadcrumb_shortcode' ) );<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode PHP function<\/strong>:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; light: false; title: ; toolbar: true; notranslate\" title=\"\">\nfunction flexy_breadcrumb_shortcode( $atts, $content = NULL ) {\n\t\t\n\t\tob_start();\n\t\tglobal $post, $shortcode_args;\n\n\t\t\/\/ Shortcode Default Array\n\t\t$shortcode_args = array(\n\t\t\t&#039;before&#039; =&gt; &#039;&lt;p&gt;&#039;,\n\t\t\t&#039;after&#039; =&gt; &#039;&lt;\/p&gt;&#039;,\n\t\t);\n\n\t\t\/\/ Combines user shortcode attributes with known attributes\n\t\t$shortcode_args = shortcode_atts( apply_filters( &#039;fbc_template_params&#039;, $shortcode_args, $atts ), $atts );\n\n\t\t\/\/ Display breadcrumb other than front page\n\t\tif ( !is_front_page() ) {\n\t\t\t?&gt;\n\t\t\t&lt;!-- Flexy Breadcrumb --&gt;\n\t\t\t&lt;div class=&quot;fbc fbc-page&quot;&gt;\n\n\t\t\t\t&lt;!-- Breadcrumb wrapper --&gt;\n\t\t\t\t&lt;div class=&quot;fbc-wrap&quot;&gt;\n\n\t\t\t\t\t&lt;!-- Ordered list--&gt;\n\t\t\t\t\t&lt;ol class=&quot;fbc-items&quot; itemscope itemtype=&quot;&lt;?php echo esc_url( &quot;https:\/\/schema.org\/BreadcrumbList&quot; ); ?&gt;&quot;&gt;\n\t\t\t\t\t\t&lt;?php\n\t\t\t\t\t\t\/\/ Breadcrumb Trail Class Object\n\t\t\t\t\t\t$fbcObj = new Flexy_Breadcrumb_Trail();\n\t\t\t\t\t\t$fbcObj-&gt;before_wrap = $shortcode_args&#91;&#039;before&#039;];\n\t\t\t\t\t\t$fbcObj-&gt;after_wrap = $shortcode_args&#91;&#039;after&#039;];\n\n\t\t\t\t\t\t\/\/ Home text &amp; icon\n\t\t\t\t\t\t$fbcObj-&gt;fbc_home_template();\n\n\t\t\t\t\t\t\/\/ For Posts Page\n\t\t\t\t\t\t$post_page_title = get_the_title( get_option( &#039;page_for_posts&#039;, true ) );\n\n\t\t\t\t\t\t\n\t\t\t\t\t\t\/\/ For WooCommerce Shop Page\n\t\t\t\t\t\tif ( class_exists( &#039;WooCommerce&#039; ) &amp;&amp; is_shop() ) {\n\t\t\t\t\t\t\tglobal $post;\n\t\t\t\t\t\t\t$page_id = wc_get_page_id( &#039;shop&#039; );\n\t\t\t\t\t\t\t$post = get_post( $page_id );\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_page_trail();\n\t\t\t\t\t\t} elseif \/* For Page and its Child Pages *\/ ( is_page() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_page_trail();\n\t\t\t\t\t\t} elseif \/* For Custom Post Type Listing or Category Pages *\/ ( is_tax() &amp;&amp; !is_category() &amp;&amp; !is_tag() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_cpt_terms_trail();\n\t\t\t\t\t\t} elseif \/* For Post Type Archive Pages *\/ ( is_archive() &amp;&amp; !is_tax() &amp;&amp; !is_category() &amp;&amp; !is_tag() &amp;&amp; !is_month() &amp;&amp; !is_year() &amp;&amp; !is_day() &amp;&amp; !is_author() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_post_archive_trail();\n\t\t\t\t\t\t} elseif \/* For Post Type Detail Page *\/ ( is_single() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_post_detail_trail();\n\t\t\t\t\t\t} elseif \/* For Default Post Categories, Tags, Parent Categories and Child Categories *\/ ( is_category() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_category_trail();\n\t\t\t\t\t\t} elseif \/* For Tag Page *\/ ( is_tag() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_tag_trail();\n\t\t\t\t\t\t} elseif \/* For Day Archive Page *\/ ( is_day() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_day_archive_trail();\n\t\t\t\t\t\t} else if \/* For Monthly Archive Page *\/ ( is_month() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_monthly_archive_trail();\n\t\t\t\t\t\t} elseif \/* For Day Yearly Page *\/ ( is_year() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_yearly_archive_trail();\n\t\t\t\t\t\t} elseif \/* For Author Page *\/ ( is_author() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_author_page_trail();\n\t\t\t\t\t\t} elseif \/* For Search Page *\/ ( is_search() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_search_page_trail();\n\t\t\t\t\t\t} elseif \/* For 404 Page *\/ ( is_404() ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_404();\n\t\t\t\t\t\t} elseif \/* For Posts Page *\/ ( NULL !== $post_page_title ) {\n\t\t\t\t\t\t\t$fbcObj-&gt;fbc_page_post_trail();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t?&gt;\n\t\t\t\t\t&lt;\/ol&gt;\n\t\t\t\t\t&lt;div class=&quot;clearfix&quot;&gt;&lt;\/div&gt;\n\t\t\t\t&lt;\/div&gt;\n\t\t\t&lt;\/div&gt;\n\t\t\t&lt;?php\n\t\t}\n\t\t$html = ob_get_clean();\n\t\treturn apply_filters(&#039;sep_fb_event_listing_shortcode&#039;, $html . do_shortcode($content));\n\t}\n<\/pre><\/div>\n\n\n<p class=\"wp-block-paragraph\"><strong>Code file location<\/strong>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">flexy-breadcrumb\/flexy-breadcrumb\/includes\/class-flexy-breadcrumb-shortcode.php<\/code><\/pre>\n\n\n\n<div style=\"height:50px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now that you&#8217;ve learned how to embed the <strong>Flexy Breadcrumb Plugin shortcode<\/strong>, understood the parameters, and seen code examples, it&#8217;s easy to use and debug any issue that might cause it to &#8216;not work&#8217;. If you still have difficulties with it, don&#8217;t hesitate to leave a comment below.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Below, you&#8217;ll find a detailed guide on how to add the Flexy Breadcrumb Shortcode to your WordPress website, including its parameters, examples, and PHP function code. Additionally, we&#8217;ll assist you with common issues that might cause the Flexy Breadcrumb Plugin shortcode not to show or not to work correctly. Before starting, here is an overview [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"name":"Flexy Breadcrumb","slug":"","version":"1.2.1","author":"<a href=\"http:\/\/presstigers.com\">PressTigers<\/a>","icons":"https:\/\/ps.w.org\/flexy-breadcrumb\/assets\/icon-128x128.png?rev=1839281","plugin_tags":"{\"breadcrumb\":\"breadcrumb\",\"breadcrumbs\":\"breadcrumbs\",\"link\":\"link\",\"menu\":\"menu\",\"navigation\":\"navigation\"}","author_profile":"https:\/\/profiles.wordpress.org\/presstigers\/","requires":"4.6","tested":"6.3.2","requires_php":"7.2","rating":94,"num_ratings":19,"active_installs":20000,"downloaded":112331,"last_updated":"2023-08-10 11:24am GMT","added":"2017-02-15","homepage":"https:\/\/wordpress.org\/plugins\/flexy-breadcrumb","short_description":"Flexy Breadcrumb is a super light weight plugin that is easy to navigate through current page hierarchy.","description":"\"Flexy Breadcrumb is a user-friendly WordPress plugin that enhances website navigation by providing a customizable and interactive breadcrumb trail. It's perfect for improving user experience.\"","shortcodes":"[\"flexy_breadcrumb\"]","footnotes":""},"categories":[1],"tags":[],"class_list":["post-1289","post","type-post","status-publish","format-standard","hentry","category-plugins"],"_links":{"self":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/1289","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/comments?post=1289"}],"version-history":[{"count":1,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/1289\/revisions"}],"predecessor-version":[{"id":1565,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/1289\/revisions\/1565"}],"wp:attachment":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/media?parent=1289"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/categories?post=1289"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/tags?post=1289"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}