you can look at line 874 in /wp-includes/taxonomy.php for the function itself. the value has stripslashes
applied and then it’s used in a prepared statement, so I’d say it’s safe. but there’s nothing stopping you from checking the value yourself first if you know what parameters it will always fall within, like ctype_alnum
or something. then check if(empty($term)), to see if anything matched and print something else if not.
Related Posts:
- What is wp_insert_term “alias_of” arg for?
- Can we have same term slug in different taxonomies?
- Set default (auto) slug prefix for Tags
- taxonomy/category term in URL slug irrelevant for post?
- Custom Taxonomy leads to 404 page
- Variable in Array Not Working
- How can I increase the length for the taxonomy term slug?
- Filtering elements by taxonomy slug
- Select query with two and two related taxonomies
- Calling an Archive Page with specific Tag/Tax ID
- Rewrite slug for WP core taxonomies
- How to have article URL like example.com/article1 and example.com/foo/article2?
- I want to change the slugs of my terms dynamically
- Attaching taxonomy data to post with wp_insert_post
- How to get taxonomy term of the current page and populate queries in the template
- tax_query in get_posts() not working?
- wp_set_object_terms() — prevent overwrite?
- Get_term_by only returns one item from array
- How to have “the most used tags” taxonomy always expanded?
- Get parent and first child taxonomy terms?
- Display the number of published posts for each custom taxonomy term?
- Priority for Categories, Tags, Taxonomies, Posts, Pages and Custom Posts with same url
- Get wordpress taxonomy archive and sort by year
- Missing term_id and term_taxonomy_id when adding a term using wp_insert_term() function
- Add custom taxonomy terms to WordPress menu dynamically & append #slug to url
- What hooks/filters are there to alter selected terms on post save?
- Filter blog archive by category in URL
- tax_query: What to pass when I want to have all terms?
- Custom Roll/Custom Post Type – Can’t Select Categories
- Trying to list terms of a custom taxonomy using get_categories
- Add a term to an attachment submitted from front end
- Get and loop posts with all taxonomy terms
- Unable to delete a Category and Tag that share same slug
- what tables uses wp_get_post_terms
- List a current posts’ taxonomy terms in a widget in WordPress
- Custom taxonomy is crashing Gutenberg
- How to show the category filter that’s shown on the ‘All post’ pages on a custom post type page in the admin area?
- Should I be using custom post types for this or terms and taxonomies?
- How can i list the categories of a post type, the taxonomy
- Set post terms on post publish
- How to display terms from a custom taxonomy in a hierarchy AND with custom html markup?
- How can I find the taxonomy in edited_{taxonomy}?
- extend HierarchicalTermSelector function with custom renderTerms
- Searching in wordpress using wp_term_taxonomy table
- WP_Query tax query part of slug
- Pulling Data from CSV vs. pulling data from database
- “AND” relation in custom taxonomies
- Problem with Query on Taxonomy
- List posts in a category grouped by other categories?
- the_terms characters not limiting
- Hierarchical list of custom taxonomy terms
- is_taxonomy() is not working
- Categorize wordpress tags
- How can i count post from my post type taxonomy
- get_term_by seems to be failing
- How to return newly added terms when using wp_set_object_terms
- Blogroll links sorted by category in a table
- How to relate a user object to taxonomy term?
- Echo taxonomy name – second level
- Taxonomy vs Post Status
- Declaring arguments for taxonomy
- Taxonomy Checkbox Admin Panel
- Prevent certain subscribers from seeing specific taxonomies (changes frequently)
- Replacing a placeholder term with a session variable value in taxonomy filter
- child_of not working in wp_dropdown_categories
- How to display posts from two taxonomies?
- Using taxonomies to handle layout?
- Return single taxonomy term outside the loop
- WP Search using taxonomy terms
- How To Query For An Empty Taxonomy Field
- How do I converge taxonomy category permalinks into one?
- Taxonomy terms are not checked when edit custom post
- Url leading to archive page, no matter what
- Checking if a product ID has taxonomy term attached not working with has_term
- Can I create a tax query to return posts that match two slugs from same taxonomy
- Taxonomy.php inheriting first post
- Display related terms from a taxonomy in an entry
- I want to get term by term_name without taxonomy
- Add specific content to a taxonomy results page
- Set the limit of taxonomy per page
- What is this Query? and why its taking too much time? Any way to optimize it?
- taxonomy terms, inverted
- generate random slug when adding taxonomy
- Slug collision between page, taxonomy and custom post type
- How to share terms between two taxonomies?
- Taxonomy Rewrite Problem
- Taxonomy terms can’t find posts from archive.php or taxonomy.php
- how to print post tags [duplicate]
- Filtering posts by taxonomy and meta_value
- GET Taxonomy ID
- Hiding an Advanced Custom Field based on Taxonomy Field selection
- Non-Recursive get_term_children()
- How do I add tags/taxonomy to images + a query field on page to query ‘albums’ (images with same tag/taxonomy)
- Delete Term via edit-tags.php
- Child Terms not Displaying on the Taxonomy Term Admin Screen
- Description of a sub-taxonomy
- Order taxonomy terms by the frequency of use in the last 30 days
- I need to add new menu item inside the custom post admin menu
- Hiding a tag from display
- taxonomy change to post/page type