• Skip to primary navigation
  • Skip to main content
OsomCode

OsomCode

Awesome code tutorials for WordPress and Genesis

  • Subscribe
  • My account
    • Edit profile
    • Favorites
    • Update credit card
  • Login

Remove page templates in Genesis Framework

Learn how to remove page templates in any Genesis Framework child theme by code thanks to this tutorial.

Genesis Framework offers 4 page templates that can be found in the “Template” drop-down in the “Page Attributes” metabox:

  • Default template
  • Blog
  • Archive
  • Landing

In most cases you don’t need them all. In fact, it’s a good idea to remove the ones your client won’t need to make their life easier and avoid confusion.

You know, less is more. 😉

Are you interested? It’s as simple as this:

Snippet to delete page templates in Genesis

Add this fragment to the end of the functions.php file:

To see this and another 847 code snippets of this website, login or subscribe here.

When you use this code, the Blog and Archive templates will no longer be displayed in the “Template” drop-down in the “Page Attributes” metabox.

Do you want to hide the “Landing” template too? Enter the next line in the previous block:

To see this and another 847 code snippets of this website, login or subscribe here.

Or if you prefer you can delete the line of the template you want to keep. It’s up to you.

Conclusions

Now you know how to remove the page templates in a Genesis child theme with a simple snippet.

Any questions? I read you in the comments.

And if you want to give me any suggestion for future tutorials, leave it in the contact form. Advantages of being a subscriber. 😉

Genesis Framework Page PHP

To leave read and make questions about this code, you can login or register.

  • About OsomCode
  • FAQ
  • Contact

Legal Notice · Privacy Policy · Cookie Policy · Terms and conditions
Copyright © 2023

Lost your password?