Skip to content

Instantly share code, notes, and snippets.

@jeremyescott
Last active July 1, 2018 23:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jeremyescott/36dfc4b9ea57e6b95c645d4d8237d549 to your computer and use it in GitHub Desktop.
Save jeremyescott/36dfc4b9ea57e6b95c645d4d8237d549 to your computer and use it in GitHub Desktop.
Remove the job slug from the URL for job taxonomy archives
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
//*
//* The Matador Team recommends you add this to a 'must-use' plugin.
//* See: https://matadorjobs.com/docs/developer/where-to-put-matador-modifications-code/
/**
* Remove the job slug from the url for job taxonomy archives
* Changes 'yoursite.com/jobs/categories' to 'yoursite.com/categories'
* Use the 'URL Slugs' section of the 'Jobs' tab in Matador settings to change the job or taxonomy slug.
*
* Requires Matador Jobs Lite or Matador Jobs Pro 3.3.0 or above.
*/
add_filter( 'matador_rewrites_taxonomy_has_front', '__return_false' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment