I am attempting so as to add title to the hyperlink to cell menu button in Divi theme. I do not wish to edit mum or dad theme, so I created little one theme and I attempt to lengthen class.
In capabilities.php I’ve:
operate divichild_includes() {
require_once get_theme_file_path( 'consists of/class-divichild-menu.php' );
}
add_action( 'after_setup_theme', 'divichild_includes' );
and in class-divichild-menu.php:
class Divichild_Builder_Module_Menu extends ET_Builder_Module_Menu {
public operate render( $attrs, $content material, $render_slug ) {
$mobile_menu = sprintf(
'<div class="et_mobile_nav_menu">
<a href="#" class="mobile_nav closedpercent1$s" title="cell menu">
<span class="mobile_menu_bar"></span>
</a>
</div>',
'upwards' === $submenu_direction ? ' et_pb_mobile_menu_upwards' : ''
);
}
}
new Divichild_Builder_Module_Menu();
I am getting deadly error “Class ET_Builder_Module_Menu not discovered”.
I attempted with prepending ET_Builder_Module_Menu with “/” and with completely different precedence of hook and it does not work.
I do know, I might add title with javascript, however I feel, that doing it in php is extra correct resolution.