Say you have a file: “wp-content/themes/my_theme_name/include/my_things.php”

require_once (get_stylesheet_directory() . '/include/my_things.php');

You can use include(), include_once(), require() or require_once() depending on your preference.

Feel free to comment if you can add help to this page or point out issues and solutions you have found. I do not provide support on this site, if you need help with a problem head over to stack overflow.

Comments

Your email address will not be published. Required fields are marked *