Hai bisogno di aiuto per modificare un codice per WooCommerce [chiuso
-
07-11-2019 - |
Domanda
Ho questo codice per mostrare il testo personalizzato nelle categorie che scelgo.
<?php if (is_product_category('furnitures')) : ?>
<p>This is the text to describe category A</p>
<?php elseif (is_product_category('kitchen')) : ?>
<p>This is the text to describe category B</p>
<?php else : ?>
<p>This is some generic text to describe all other category pages,
I could be left blank</p>
<?php endif; ?>
Come posso fare in modo che il testo sia mostrato anche nelle sottocategorie di ciascun genitore. Nel codice sopra ci sono "mobili" e "cucina" il genitore e hanno alcune sottocategorie.
Grazie!
Nessuna soluzione corretta
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a wordpress.stackexchange