Hot answers tagged

3

Here you go. Since you already have the menu-id all you need is: $menu_item_defaults = array( 'menu-item-db-id' => $menu_item_db_id, 'menu-item-object-id' => 0, 'menu-item-object' => '', 'menu-item-parent-id' => 0, 'menu-item-position' => 1, ...


2

If you're sure you don't need those plugins and if TGM is not tied up with any required licenses for your plugins, just pull TGM Plugin Activation right out. It's a three step process. One: find and delete the plugin registration function. <?php /** * Required and Recommended Plugins */ function prefix_register_plugins() { /** * Array of ...


2

As Caspar has alluded to in a comment, a child theme descends from a parent theme - you wouldn't add a pre-existing child theme on to a parent theme the same way a parent human is needed to make a child human ;) The theme you are working on now is a parent theme, whether it came from another theme base originally or not. You have two ways forward: You ...


2

Why not use a completely separate repo for each child-theme site once its established? Clone the master repo when spinning up the environment, remove the Git directory, init a new Git repo, and push it up to wherever? Now each child theme can be developed independently of each other. Alternatively, if you're using the same site as a base and making minor ...


2

Sorry I can not comment yet on this site Could you be removing an action before it is registered? Have you tried wrapping this with an on init hook? Perhaps using remove_filter would be a better choice. function my_init() { remove_filter( 'storefront_header', array( 'Galleria_Structure', 'galleria_top_bar_wrapper' ) ); remove_filter( ...


2

Child themes are allowed to override templates, not simply arbitrary PHP files. In WordPress, a theme consists of a bunch of PHP files which are used as Templates. You can find a list of those files in the Template Hierarchy. Those specific template files can be overridden with new ones, but unless the parent theme has some special means for you to ...


1

I agree with @Zlatev that you probably wouldn't want to do this clientside. There are easier ways to include less. There are plugins that allow you to do this. Even jetpack has less support. If your goal is to include this in your theme you can use wp-less. Just download that plugin and drop in somewhere in your theme and include it in your ...


1

In regard to WordPress post paged, I would use /player-12345 or other structure as url specific page rather than /player/12345. How to create new url structure for page Creating additional url structure, you need WP_Rewrite, there are a couple of filters that you can fire with your function. For Page, you can filter page_rewrite_rules. See example code on ...


1

Your child theme functions.php loads before the parent theme's, so you're trying to remove the action before it's added by the parent theme. Hook after_setup_theme to remove/add, which is executed after both child and parent load. add_action( 'after_setup_theme', 'wpd_wp_head_function' ); function wpd_wp_head_function() { remove_action( 'wp_head', ...


1

You need to create attachment.php in your child theme. Please check here for more details.


1

All the information you need can be found here: https://codex.wordpress.org/Child_Themes The important parts to get it up and running would be to: Make sure the parent theme exists (the complete accesspress-lite theme in your case) Create a unique folder name for your child theme. Create a style.css file in your child theme folder. /* Theme Name: Your ...



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