WordPress.org

Ready to get started?Download WordPress

Forums

Extra taxonomy sort option (1 post)

  1. jdtruran
    Member
    Posted 1 year ago #

    Hi,

    I’ve been asked to add an extra taxonomy to the portfolio of a site. I’ve managed to pick up bits and pieces of pre-existing code and everything is working except the front end seems to be displayed on a different template (of which I've amended some CSS to appear more like the other pages). The website can be viewed at http://contentportal.greenhatmktg.com.au/ and the new taxonomy is “Themes”.

    What I’ve done:

    1. Added the following code to the Funtions file: register_taxonomy(‘portfolio_theme’, ‘avada_portfolio’, array(‘hierarchical’ => true, ‘label’ => ‘Themes’, ‘query_var’ => true, ‘rewrite’ => true));

    2. Added the following code to the single-avada-portfoio.php file: <?php if(get_the_term_list($post->ID, ‘portfolio_theme’, ”, ”, ”)): ?> <?php _e(‘Themes’, ‘Avada’); ?> <?php _e(‘Themes’, ‘Avada’); ?>: <?php echo get_the_term_list($post->ID, ‘portfolio_theme’, ”, ”, ”); ?> <?php endif; ?>

    Any assistance would be greatly appreciated. Please let me know if you need any more info. Cheers.

Topic Closed

This topic has been closed to new replies.

About this Topic