$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>Wordpress Taxonomy Menu|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

Wordpress Taxonomy Menu

matteradmin10PV0评论

I have got the following simple code.

<ul id="filter"><?php       
echo '<li class="active"><a href="#" class="all">All</a></li>';             
if ( $count > 0 ) {             
    foreach ( $mylinks as $mylink ) {
        echo '<li>'.'<a href="#" class="'. $mylink->slug .'" >';
        echo $mylink->name;
        echo "</a>";
        echo "</li>";
        }
    }   
?>

The above basically returns the following:

<ul class="filter">
<li class="active">
    <a class="all" href="#">All</a>
</li>
<li>
    <a class="education" href="#">Education</a>
</li>
<!-- Etc. --></ul>

What I want is to have the taxonomy terms, (i.e. say taxonomy Education to link to an independent page: and on that page have all the custom post types with the taxonomy 'education' displayed on the page.

PS: Displaying the taxonomy terms is not a problem, the problem is linking the displayed taxonomy terms (in the code above) to an independent page (). This must happen all dynamically.

Is it possible? Please share your suggestions or links to tutorials.

One more question. What is the exact custom taxonomy URL? Is it ?

I have got the following simple code.

<ul id="filter"><?php       
echo '<li class="active"><a href="#" class="all">All</a></li>';             
if ( $count > 0 ) {             
    foreach ( $mylinks as $mylink ) {
        echo '<li>'.'<a href="#" class="'. $mylink->slug .'" >';
        echo $mylink->name;
        echo "</a>";
        echo "</li>";
        }
    }   
?>

The above basically returns the following:

<ul class="filter">
<li class="active">
    <a class="all" href="#">All</a>
</li>
<li>
    <a class="education" href="#">Education</a>
</li>
<!-- Etc. --></ul>

What I want is to have the taxonomy terms, (i.e. say taxonomy Education to link to an independent page: http://website/education and on that page have all the custom post types with the taxonomy 'education' displayed on the page.

PS: Displaying the taxonomy terms is not a problem, the problem is linking the displayed taxonomy terms (in the code above) to an independent page (http://website/independent_page). This must happen all dynamically.

Is it possible? Please share your suggestions or links to tutorials.

One more question. What is the exact custom taxonomy URL? Is it http://website/taxonomy/education ?

Share Improve this question edited Feb 9, 2019 at 0:02 fuxia 107k39 gold badges255 silver badges461 bronze badges asked Nov 22, 2012 at 13:03 user23355user23355
Add a comment  | 

1 Answer 1

Reset to default 0

If I understood this correct, then you need a taxonomy.php file.

LINK

Articles related to this article

Post a comment

comment list (0)

  1. No comments so far