The “page” in WordPress usually refers to a “PAGE page”, as in only post of page
post type. Not any page of the site in general.
What you want to link to is category archive. Something along this should work:
echo get_category_link( 'cooking-sauces' );
If cooking-sauces
is slug of a term that belongs to custom taxonomy (as opposed to native category taxonomy) you will probably need to use something like:
echo get_term_link( 'cooking-sauces', 'your-taxonomy-slug' );
Related Posts:
- Allow two posts (from different categories) to have the same slug
- How to Remove Parents Category Permalink from Posts
- Get posts with at least one category in common with current post?
- WordPress custom slug (endpoint) and compare all links
- What is an equivalent of single_cat_title for getting the slug of the category?
- php script to change slug in post automatically
- Remove slugs from custom posts type
- Test the existence of a page/article by its URL, taking in consideration the URL rewriting by filters
- Get nice name of category from slug (remove dashes of category)
- Custom PHP form needs refresh to load page correctly
- Child-Theme Category View with modified permalinks (%category% removed)
- Rewrite rule not working, but only when parameter is text
- How does Permalink work with the AMP plugin after Removing Parent Permalink Catalog from Posts
- Hide a specific category title from displaying on site
- Exclude a category slug on pagination
- Custom content using in_category
- WordPress using get_term to retreive slug not working as expected
- Weird slug in archives permalink
- get_category only returning details for ‘uncategorized’
- Remove /category/ from category (archive) page URLs (without using a plugin)
- Getting key value of WP_Term object in wordpress
- Counting number of posts in a category and its sub categories and displaying result using shortcode
- Looking to exclude blog posts from category Previous/Next buttons
- add_rewrite_rule with bottom priority doesn’t handle the WordPress pages
- How is WordPress manipulating the posts like there are folders?
- Add HTML Attributes To Anchor Tags In `wp_list_categories()` Function
- Do changes to WordPress permalink custom structure affect old urls?
- Rename “Portfolio” slug?
- Where do posts get the sidebar from?
- How do I attach a php file to an arbitrary slug and still have access to the wp-core functions?
- How to query for pages/post depending on slug?
- get post based on category chosen in drop down – The ajax method
- Global variable $post returning incorrect object
- Proper syntax or method for keeping url in modified isotope / category links
- how do I get a specific post from a post with a subcategory in WP
- WP grandchild categories in nested ul li
- Get page that displays all children of taxonomy parent
- WordPress returning 404 for multisite pages
- selected option if current category is the value
- Alert Bar section within WP loop is displaying even though there are no posts
- Redirect to another page using contact form 7? [closed]
- Dilemma of Populating all the categories in a drop down list
- JSON REST API WordPress only showing first 10 categories
- How to get post permalink url without a href
- Get all categories post is not in
- stripping tags from excerpt in WordPress is not working
- Use the category name instead of category slug in permalinks
- Rewrite with pagination /foo/page/2/ to posts of a given category, page 2
- page-slug.php not working but only for specific slug
- How to get category name or ID by post?
- Listing titles and custom fields of entries within subcategories
- random display categories – change url
- Do not duplicate posts with multiple categories in multiple loops
- Removing sidebar on category pages
- Search only working on front page (index) , not working on other pages
- go to home page when i select default in select-box
- Adding wp_list_categories to a specific div that was appended using jQuery
- WordPress permalink issue
- Counting number of posts in multiple (sub)categories using shortcode
- Wrong Number of Products When Hiding Subcategory Products From Showing In Parent Category
- How do I edit the terms output args or array data?
- Change category thumbnail size
- Display Visual Composer shortcode if a post belongs in specific categories
- admin panel – How to remove “delete” button from category editing page
- Get parent category name when only child category is applied to a product
- Multiple Tag Filtering
- Polylang and template files
- Notice: Undefined variable
- Show subcategory name selected in specific category woocoommerce
- WordPress generates weird permalinks
- Exclude category and post from loop in custom category.php
- Admin backend, show post from a category and exclude the posts from subcategories
- What is the proper way to call a function (from functions.php) on a link click?
- How do I generate formatted permalinks as specified in backend options?
- PHP drop down menu for my get_category child of
- Short code into PHP
- Need Quick Help With Product Category Page
- Need to adjust condition to say if I’m pulling categories from a post, to pull only the first one
- How to solve 404 permalink errors on nginx server
- add_rewrite_rule questions
- Rearrange get_categories array compared to another array
- set new link as permalink
- echo variable containing html and the_permalink();
- Search in particular category in wordpress
- Query seems to be duplicated
- Top menu disapears in Category Pages when filtering using ACF
- append links with unique number string
- Remove the_content From Loop
- Category List in Theme Options Page
- Code that displays images – images get shown multiple times
- custom data in url
- Display post of specific category on page
- Displaying categories
- Product Category Page in Full Width
- Display all categories (with link) of custom post type – WordPress
- Add any username as link prefix and show data from that specific user’s profile on wordpress pages – with no login required
- how to goto specific page number including title with permalink
- How to extract URLs from wordpress taxonomies
- WordPress 6.1.1 UTF8 Slug Limit Increase
- How to add custom prefix before category base for category page URL?