Last active
November 22, 2016 22:22
-
-
Save edpittol/4abe95882b8c89f59839afcb409788c9 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
/** | |
* Add Flower font to the theme options font list. | |
* | |
* @param array $custom_fonts Current custom fonts. | |
* @return string[string][string] The Web fonts section. | |
*/ | |
function mytheme_redux_custom_fonts( $custom_fonts ) { | |
return array( | |
'Web Fonts' => array( | |
‘flower' => 'flower' | |
) | |
); | |
} | |
add_filter( 'redux/option_name/field/typography/custom_fonts', 'mytheme_redux_custom_fonts' ); |
This file contains hidden or 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
/** | |
* Add Flower font stylesheet. | |
*/ | |
function mytheme_enqueue_scripts() { | |
wp_enqueue_style( | |
'flower-font', | |
get_stylesheet_directory_uri() . ‘/assets/fonts/flower/stylesheet.css' | |
); | |
} | |
add_action( 'wp_enqueue_scripts', 'mytheme_enqueue_scripts' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment