Public Ticket #3831608

Disable b2bking_fonts_dmsans

Closed
Comments
21 Tickets 12
Bob Hufkens started the conversation 2 years ago on March 4, 2025 at 10:20am

Hi, I can't seem to disable b2bking_fonts_dmsans using any method (wp_enqueue_scripts, wp_footer, wp_head).

How should it be done?

Thanks,

Bob

21 Tickets 12
Bob Hufkens replied 2 years ago on March 4, 2025 at 10:31am

I also need to disable all Roboto files loaded by the plugin. It's important not to impact my client branding guidelines and just inherit the theme fonts.

2,762
KingsPlugins replied 2 years ago on March 5, 2025 at 6:24pm

Hi there,

It should be possible to replace B2BKing's fonts with a different font, or to set it to inherit other site fonts.

To do that, please add this CSS to your site:

:root {
		    --b2bking-font-family-a: inherit !important;
		    --b2bking-font-family-b: inherit !important;
		    --b2bking-font-family-c: inherit !important;
}

 

If the above does not work for you for any reason, I'd suggest to also try adding it as a PHP snippet rather than as CSS directly, e.g.

add_action('wp_head', function(){
	?>
	<style>
		:root {
		    --b2bking-font-family-a: "Arial" !important;
		    --b2bking-font-family-b: "Arial" !important;
		    --b2bking-font-family-c: "Arial" !important;
		}
	</style>
	<?php
});

 

This should replace all plugin fonts, including Roboto.

Let me know if that can solve it.

 

Kind regards,

Stefan

21 Tickets 12
Bob Hufkens replied 2 years ago on March 6, 2025 at 8:01am

Thanks. Some woff files were still being loaded though because the css vars aren't used consistantly in the css.

But based on your input I managed to override everything and stop the files from being loaded. I ended up using this:

[class*="b2bking"], [id*="b2bking"]{font-family: inherit !important;}

It would be ideal if the fonts could be disabled with a setting.

Thanks.

1

Sign In