I have a taxonomy "Medium" set up. Loving the ability to show popular terms by the way.
I would like to encourage users to select from existing popular terms first, rather than creating their own. This will encourage users to be consistent with them- hopefully avoiding ending up with "Printmaking" and "Print Making", for example.
Is it possible to have the Popular terms always visible, above the "Add" field? I've added a quick screenshot showing what I mean.
Hopefully that makes sense. Cheers!
Hello,
I assume we are talking about Toolset form for creating/editing post.
If it is, there isn't exact feature, but you can display the exited terms as checkboxes field, and display an "Add New" link below those checkboxes field, for example taxonomy "Category":
<div class="form-group">
<label>Categories</label>
[cred_field field='category' display='checkbox' output='bootstrap']
[cred_field field='category_add_new' taxonomy='category' type='add_new']
</div>
More help:
https://toolset.com/documentation/user-guides/cred-shortcodes/#cred_field
Hi Luo, that sounds perfect. However, I get an error:
There is a problem with medium_add_new field. Please check CRED form.
I have attached screenshot of my code. Did I need to change anything elsewhere too?
It just occurred to me that it's probably because my Medium taxonomy is set to flat... Is there a way to get around that? It doesn't make sense to have Medium hierarchical in this case.
Otherwise, could I convert it to hierarchical and remove the ability to add child terms somehow?
You are right, the argument "display" works only for the hierarchical taxonomy, see our document:
https://toolset.com/documentation/user-guides/cred-shortcodes/#cred_field
display. Optional. Used by fields for Hierarchical Taxonomies (like Categories) to signify the mode of display (ie. “select” or “checkbox”).
There isn't such a built-in feature for these:
remove the ability to add child terms of hierarchical taxonomy.
But for the flat taxonomy, you can use a little CSS codes to display the popular terms by default, for example wordpress built-in taxonomy "Tags", you can use below codes in your Toolset form, it will be able to display a input box, :
[cred_field field='post_tag' class='form-control' output='bootstrap']
click "CSS Editor", add below codes:
.shmpt-post_tag{
display:block !important;
}
It will show the popular terms by default.
Sounds fine to me- cheers!