• Resolved pengo

    (@pengo)


    I’m building a website with a child theme inherited from Quark, and trying to avoid editing the original Quark files so I can update them without fear of breaking the site.

    To this end I’ve been wrapping functions within functions.php to allow overloading in the child theme. For example:

    if (!function_exists(‘quark_fonts_url’)){
    function quark_fonts_url() {

    }
    }

    Of course, I have to reapply these wrappers when there’s a Quark upgrade (as there was this morning NZT), but it’s still easier than having to reinstate detailed code changes.

    In a future upgrade, would you consider adding these wrappers yourself?

    Thanks for a great theme.

Viewing 1 replies (of 1 total)
  • Theme Author Anthony Hortin

    (@ahortin)

    Hi,

    Sure I can add some more of those wrappers for you. Was is just that function in particular that you were trying to override?

    If it is, you should be able to use this in your Child theme to dequeue my fonts:

    function mytheme_dequeue_fonts() {
        wp_dequeue_style( 'quark-fonts' );
    }
    add_action( 'wp_enqueue_scripts', 'mytheme_dequeue_fonts', 11 );

    You can then go and create your own function and enqueue your own fonts.

Viewing 1 replies (of 1 total)
  • The topic ‘Request for conditional inclusion of key methods’ is closed to new replies.