This video goes over how to change the “Downloads” label and slug to “Themes” throughout the plugin and theme. The labels are what you see in the WordPress dashboard and the slug is the URL.
This will allow us to navigate to http://yoursite.com/themes instead of http://yoursite.com/downloads which is also nice!
Steps from the Video
- Go to the Easy Digital Downloads documentation and grab the function that changes the post type labels. You can find that code here.
- Create a new file called
edd.php
in the/inc/
directory and paste in the code. - Replace all instances of “Products” to “Themes” and “Product” to “Theme”
- Replace the text domains from “your-domain” to match your theme text domain
- Include the new
edd.php
file in our mainfunctions.php
file with the following code:1234/*** Easy Digital Downloads*/require get_template_directory() . '/inc/edd.php'; - Refresh the WordPress Dashboard and notice the new labels!
- To change the URL slug go grab the EDD constant here
- Put this code in our
edd.php
file and change ‘my-downloads-slug’ to ‘themes’ - From the WordPress Dashboard go to Settings -> Permalinks and click Save
- Reload an individual theme on the front-end and notice your new slug!