Ok I got it!
That’s the code for my search-results.php
<?php
include('../../../wp-load.php');
$term=$_GET["term"];
$json=array();
$terms = get_terms( 'produits' );
if ( ! empty( $terms ) && ! is_wp_error( $terms ) ){
foreach ( $terms as $term ) {
$json[]=array( 'value'=> $term->name );
}
}
echo json_encode($json);
?>
Thanks milo for your help ! I needed to use get_terms !
Related Posts:
- WordPress custom taxonomies new/edit post autocomplete
- Using pre_get_posts to rewrite search query to display posts from multiple taxonomies
- Exclude Specific Term from Search
- WordPress database error: [Not unique table/alias: ‘wp_postmeta’]
- WordPress Search – display taxonomy terms in results
- Custom taxonomy only shows 0 in autocomplete for terms and “Choose from the most used tags”
- How to find taxonomy name using only taxonomy TERM ID (or taxonomy term name)
- Sort posts by number of matched terms
- How to add custom taxonomy to search
- Taxonomy.php issue with search and filters
- Extending wordpress search to include excerpts and taxonomies?
- How to filter WordPress search, excluding post in some custom taxonomies?
- how to search in custom fields & custom taxonomy for custom search
- Search by type posts and taxonomy
- How to add autocomplete to custom taxonomy for CPT
- Autogenerate Front End Form Field With jQuery
- Creating a custom search form
- How to implement custom search with input fields?
- How do I keep the page I’m on within the URL when running a search on a taxonomy?
- Add multiple taxonomy filters to edit.php that support search
- Extend & Search Native WordPress Image Galleries With Tags and Taxonomies?
- Custom Taxonomy Not Working When added to WordPress Search
- Search Tool only refreshes Page without showing results
- WordPress thinks my custom taxonomy pages are search pages #seo
- Removing “s” from search with custom parameters
- Passing form inputs into multi-taxonomy query
- Custom URLs in Custom Search Results
- Search Query for Multiple Terms In Same Taxonomy
- Use an HTML Element To Filter Taxonomies In WP Search
- Why isn’t the ‘no results’ being shown when a query returns no results?
- Clean Custom URL for Serach + Custom Taxonomy
- Advanced search redirecting to another page then filter further
- Search only custom taxonomies
- How do I make multiple dependent input fields that use the jquery autocomplete function?
- Geographic search with taxonomy structure [duplicate]
- search using multiple taxonomies and keyword
- Taxonomy or Custom Field
- Multiple Drop-Down custom taxonomies search
- Filter with two id of the same value CPT UI(taxanomies)
- Amend taxonomy to search in wordpress admin
- Include get_term_link inside search
- Product custom taxonomy is not found when space in name
- Rewrite Search URL Permalink For CPT Custom Taxonomies
- Search custom taxonomy via query-string?
- How to exclude woocommerece product category in search results?
- Post not showing in my custom advanced search
- Include attachments with a custom taxonomy in search
- Custom taxonomy displayed in search results
- How to perform a search inside a specific taxonomy category
- Custom taxonomy auto suggest not working in wordpress admin
- Custom Taxonomy, shows empty value (home page of website)
- Advanced WordPress search form based on custom taxonomy and custom meta value
- Custom Search only for my Custom Taxonomy Page – data
- Search and filter with custom field in taxonomy
- Debugging Missing Elements in Taxonomy
- Getting the parent terms adds additional empty markup [closed]
- Display taxonomy term slugs
- Next/Previous links in custom taxonomy, where item may belong to multiple terms
- WordPress WP_Query Array Custom search via taxonomies
- How to query authors by custom taxonomy?
- Automatically Populate Post Taxonomy Data Based on Post Author Meta Data?
- Get Posts by tag from a custom taxonomy
- Display custom post term or taxonomy
- Attaching meta box to specific category/taxonomy in custom post type
- Permalink Rewrite to include Custom Taxonomy Term
- Change Permalink to Value of Custom Field
- Trying to Display Number of Posts in Term
- Extra fields on categories that is available via the WP-API?
- Can I use multi (sub) levels of relation (AND | OR) on custom query?
- WordPress taxonomy radio buttons
- Tax Query not working
- How to display custom taxonomy
- Taxonomy archive page have no post
- Index page of posts tagged with two separate taxonomies
- Display list of custom taxonomies from a custom post type ordered by their parent
- Multiple taxonomies, what should the permalink look like?
- How do you move custom fields to custom taxonomies using WP Queries
- WordPress hiding posts without content on custom taxonomy query. How to solve?
- Child Pages and Custom Taxonomies
- get meta fields and taxonomy of any post type
- How to make an sql query to exclude everything but custom taxonomy terms in table wp_terms?
- Custom taxonomy – query returns an error
- Where to put a migration script to switch post information?
- rewriting for custom taxonomy rewrite
- Display the first tag assigned to a post
- Change taxonomy of posts
- Custom Taxonomy registered with multiple custom posts
- Run next query based on first query’s term
- Query Number of Loaded Posts in Loop
- Producing a list of media library items categorized under a certain taxonomy item
- Why is it defaulting to “uncategorized” even after I select a custom taxonomy
- Get the original menu item name string instead of the label
- Custom taxonomy list in two columns
- How to use tax_query other than by slug or id or solve custom taxonomy tags conflicts with pre-existing tags?
- Tax query array terms display out of order
- Pagination with custom query (not using posts)
- Order posts with custom taxonomy array
- Remove taxonomy menu without removing the metabox?
- Custom taxonomy list in Worpdress
- How to change taxonomy slug?