When registering your CPT, the rewrite and has_archive parameters will control the URLs (untested):
register_post_type( 'course', array(
...
'rewrite' => array(
'with_front' => false,
'slug' => 'course',
),
'has_archive' => 'courses',
);
Related Posts:
- How to remove /index.php/ from URL’s
- Run WordPress frontend and backend in different domains
- How to remove “http://” When Echoing URL?
- Change homepage url
- How can I change all links on pages to point to a different domain from where the site is hosted?
- Remove site root trailing slash
- URL parsing – what is it?
- Changing my site url from azure.net to custom domain
- Remove / from www.example.com/ [closed]
- Avoid the removal of “https:” from URLs
- Confusion about Site url and directory
- WordPress get parameter ‘unapproved’ and ‘moderation-hash’
- Changing the website URL to the root folder
- Showing my server ip in source code for several links not for all links
- How do I avoid messing up URLs when switching from example.com/subdir to example.com?
- Cannot access WordPress website from external IP while internally it is working properly [closed]
- DNS – Change WordPress Site Name?
- Alternatives to site_url() and get_template_directory_uri()
- What is the best way to revert to www version of domain name?
- Changing siteurl in the database not working
- How to make a seo friendly URL of 2 different pages with same words
- Why my URL has an unknown character string?
- Two domain site: Link base URLs point to wrong domain
- Making a site URL
- Can’t change url because site address is greyed out
- How does routing on wordpress work?
- Redirecting to old domain after migration
- Unwanted media library URLs in posts?
- use query string in URL to display content on the page
- Update media file url in wordpress media library
- Get taxonomy slug from url
- Load images with http urls inside https post
- List of default WordPress URLs
- add_query_arg() One Key with multiple values
- WP redirects all pages from new domain to old domain
- As soon as I add a custom query_var using the filter, my pages point to an archive page – why?
- redirect 301 old url to new url
- How to update media links in WordPress after migration?
- Concatenate site_url and string doesn’t work
- Why ids in urls don’t work but slugs do?
- How to create a page for authors? like www.myblog.com/author/
- Check request URL for pattern
- Best way to give site sub-page it’s own domain?
- Dynamically change page title from URL param
- Rewrite WordPress Standard Feed URL – /feed/ to feed.xml
- wp_insert_post – How do I prevent incremental numbers on child pages?
- Dynamic URL based on user_metadata
- Check if user is logged in to site A when visiting site B
- Localhost port is missing on some links after downgrading MAMP [closed]
- Why am I seeing all these weird ‘loginid’ requests?
- URL issue after migrating to dev site
- Misentered the site address url. How to recover? [closed]
- How to call for bloginfo inside function in functions.php?
- Moving a WordPress site – Installation issue
- wordpress url correction
- What is the best way to figure out which template file that a “pretty permalink” is using?
- Can’t change the wordpress site url
- Wrapping add_query_arg with esc_url not working
- Relative URLs within site
- Using WordPress for a site’s static marketing pages and blog at different URLs
- Need to check if user is on a particular page
- How to set path to the image instead of alt in media.php?
- Go back to my home page
- Changed domain name and all the 301 redirects work except the ones for the thumbnail image which return 403 Forbidden error
- Changing url of author page
- How to get previous and Next Post Url in the_post_navigation
- Thousands of unwanted URLs/pages with “0” in slug created
- Multisite problem with unexisting paths to CSS etc
- How to remove % character from url
- Encode URL for WhatsApp “click to chat” without loosing accented characters
- append currency to URL
- Create 600 links to separate files on google drive
- Locked myself out of WordPress because I changed my URL and computer shut down
- Cant access my wordpress.org locally
- There is how to change url domain on some posts?
- I changed the URL [closed]
- WP site homepage displays url link at beginning of each featured post
- how to set url in admin option page
- Unable to login after changing WordPress site url
- Why is my WordPress URL shortened
- mysterious issue with stop words in urls not working – how can I restore multiple url access?
- What does this structure of the URL mean? http://www.example.com/?i=0
- Moving Site: Is Re-downloading Files After Changing URLs necessary?
- How to create a dedicated folder for specific role via registration
- How to get the correct URL on my wordpress site?
- WordPress custom form post to different page
- How to redirect WP post with a specific word in the URL
- Avoid too long words in a post title, post content or comment but only if its not a url
- Change URL to filter posts
- Modify WordPress to not replace + (plus) characters from URLs?
- How to remove slug from url (custom post type)
- Enabling canonical links to force search engines to go to site.com rather than site.net [closed]
- Why my wordpress site URL does not begin with my domain?
- I changed my url and cant access my site, Help?
- Accidentally changed the url
- Select Tab name to show in browser’s URL
- What purpose does /embed/ URL have and how to avoid SEO problems?
- Leave login URL for my user beautiful
- Incorrect Post URLs
- How to hide ids from URL [closed]