I have been trying google for this, but not so easy to search for. I have a custom hierarchical taxonomy, something along the lines of:
Chainsaws
- Electric
- Petrol
- Other
Grasscutters
- Electric
- Petrol
- Other
What I need to do is create an index page, retaining the hierarchical structure.
The closest I have come to doing it is with:
$products = get_terms('product-type');
foreach ($products as $product) {
$out .= $product->name;
}
But this just shows the ones in use, and loses it hierarchy 🙁
Any insights are very welcome.
Thanks in advance
Andy