I have our portfolio page here: http://www.slarc.com/portfolio-view/central-control-building-east-texas/
The orange links below the project title are manually inserted on the page content. Is there a way to call in a the post categories to make this automatic?
The template I'm using doesn't have our portfolio posts under WP Posts. It's under a custom post-type titled "Portfolio".
I have received this code below. But I don't know how to add it to my page. When I tried everything on the page below the PHP code disappeared.
<?php
$args = array(
'type' => 'post',
'child_of' => 0,
'parent' => '',
'orderby' => 'name',
'order' => 'ASC',
'hide_empty' => 1,
'hierarchical' => 1,
'exclude' => '',
'include' => '',
'number' => '',
'taxonomy' => 'your_custom_taxonomy',
'pad_counts' => false );
$categories = get_categories($args);
echo '<ul>';
foreach ($categories as $category) {
$url = get_term_link($category);?>
<li><a href="<?php echo $url;?>"><?php echo $category->name; ?></a></li>
<?php
}
echo '</ul>';
?>
Thanks, Lorne