Tag Info

Hot answers tagged

2

Using after_switch_theme will activate the theme (which is fine as we want to run the check within the context of the new theme). So if the check fails, we can simply switch back to the previous theme (passed via after_switch_theme as $oldtheme). If WPML is missing ($wpml_is_missing = true;) we will output an admin notice and switch back using ...


1

You can do this by adding the following class in your theme for admin options; Custom-Metaboxes-and-Fields-for-WordPress And you can call your repeatable fields with some thing like this; array( 'name' => 'Name of field', 'id' => 'prefix_option_name', 'type' => 'text', 'default' => '', ...


1

The problem, as idiotic as it may seem, was that I had inadvertently included the template name of my standard subpage template into my landing page template. WP didn't know what to do with it...


1

So, yes, WP can be quite a mess, more so in complicated themes. Some of it is just experience and chewing through sources. There are, however, several things that can help to determine what is happening via code: Dumping get_included_files() will get you all PHP files loaded up to that point. It's messy, but sometimes it's what it takes. There are plugins ...



Only top voted, non community-wiki answers of a minimum length are eligible