My theme is not translated

Make sure you put your function inside after_setup_theme action hook add_action( ‘after_setup_theme’, ‘load_translation’ ); function load_translation() { if( is_dir( get_stylesheet_directory() . ‘/languages’ ) ) { load_theme_textdomain(‘adifier’, get_stylesheet_directory() . ‘/languages’); } else { load_theme_textdomain(‘adifier’, get_template_directory() . ‘/languages’); } Also, you have to make sure your theme domain is matched with the translated file. For an easier … Read more

Very slow page loads

The problem as it turned out was the fusion-builder-mobile-layout-creator plugin. By going into settings for the theme and unchecking mobile layout (which checked itself again immediately), it cleared the buildup of entries. It may recur but that’s the fix. We might have to uninstall the plugin entirely longer term.

Is there a way to have WordPress autodetect page templates in the page-templates directory and any sub-folders?

You should be able to do this with the theme_templates filter (see the get_page_templates() function). What you need is a function that walks through the sub-directories and returns all the page templates. Then you hook it into that filter. You could create a function based on get_post_templates(), replacing the call to get_files() with a function … Read more