How to

This is a list of typical things we need to add/edit/adjust for everty project

  • Custom Post types

    1. Duplicate the cpt template file /includes/cpt/template-cpt-book.php and change the prefix of the file name to the id of your new cpt.
    2. Go to /includes/cpt/custom-post-types.php and add a the filename to the array.
    3. New cpt articles will use single.php as the template file. Single.php will check if the article is a cpt and try to load the custom template from /components/template_part/content-single-cpt_id.php and fallback to content-single.php if it does not excist. Nice ha?
      <?php inc('template_part', 'content-single', null, get_post_type()); ?>
      
      Note! Remember to change the name of the function that adds a custom title in template-cpt-book.php.
  • Custom menu

    Add a new menu in setup() -> lib/init.php

results matching ""

    No results matching ""