Created
August 11, 2022 20:32
-
-
Save pascalbajorat/e43e4da983217527fbab8572632e538d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Lokale Google Fonts by Bajorat Media | |
* Description: Lokale Google Fonts by Bajorat Media - ACHTUNG: Die Fonts müssen manuell im Plugin angepasst werden. | |
* Author: Bajorat Media | |
* Author URI: https://www.bajorat-media.com | |
* Plugin URI: https://www.bajorat-media.com/?p=16041 | |
* Version: 1.0.0 | |
**/ | |
/* Security-Check */ | |
if ( !class_exists('WP') ) { | |
die(); | |
} | |
// Font-Datei registrieren | |
function bm_local_fonts() { | |
// Beispiel für wp_dequeue_style | |
wp_dequeue_style( 'vc_google_fonts_source_code_pro200300regular500600700900' ); | |
wp_enqueue_style( 'local-google-fonts', plugin_dir_url(__FILE__) . 'fonts.css' ); | |
} | |
add_action( 'wp_enqueue_scripts', 'bm_local_fonts' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment