WordPress.org

Ready to get started?Download WordPress

Forums

Removing Open Sans from Twenty Twelve Theme (2 posts)

  1. marthaleeturner
    Member
    Posted 1 year ago #

    I was playing with GTMetrix and a test site I have running a child theme of Twenty Twelve. I noticed in the Timeline that it was calling not only my fonts from Google but Open Sans (I hadn't read enough to know Open Sans is a "feature" of the new theme).

    Since I didn't want to use it, I thought I'd remove it, and found (in functions.php) the following note:

    * To disable in a child theme, use wp_dequeue_style()
    	 * function mytheme_dequeue_fonts() {
    	 *     wp_dequeue_style( 'twentytwelve-fonts' );
    	 * }
    	 * add_action( 'wp_enqueue_scripts', 'mytheme_dequeue_fonts', 11 );
    	 */

    So I un-commented it and put php stuff around it, put it in functions.php (I already had one from registering an extra menu).

    It removed Open Sans--page looks good, no call for Open Sans in the Timeline any more. Small problem: no backend to the site displays! Is it all in Open Sans, or what?

    I removed the dequeue stuff from functions.php, and all is well. But I really don't want to be calling fonts I am not using.

  2. lynk
    Member
    Posted 1 year ago #

Topic Closed

This topic has been closed to new replies.

About this Topic