Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #347529

    How can I replace the class-framework-widget.php with a new one in child theme’s folder? Currently it is in framework/php/ folder. Or is there another way to edit the code of the enfold’s widgets?

    #347544

    Hey!

    In this case what you need to do is re-create the classes/functions found in that file, every class/function is prefixeed by this if statement:

    if (!class_exists('avia_fb_likebox'))
    

    So you just need to define a class with the same name in your child functions.php file, like:

    class avia_fb_likebox extends WP_Widget {
    

    Cheers!
    Josue

    #510744

    Hmm I think I not understand it. Hmm is it possible to copy the Framework ” class-framework-widgets.php ” to the child theme and register it?

    I tried your example. And copied it in my functions.php

    class avia_newsbox extends WP_Widget {
    	echo image;
    }
    

    But I get errors. Can you be a little bit mor porecise how to change a function in the framework?
    I want to remove the images in the sidebar of the avia_newsbox widget

    #510996

    Hey!

    Try including the preceding conditional too:

    if (!class_exists('avia_newsbox')){
    ...
    }

    Cheers!
    Josue

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.