Quantcast
Channel: WordPress.org Forums » All Posts
Viewing all articles
Browse latest Browse all 135067

Wolfman1000 on "Using Googlefonts in Childtheme-The right way?"

$
0
0

Hi All,

I'm attempting to incorperate using googlefonts into my Childtheme and have got it working by setting up the following function in a functions.php file I made for my child theme.

<strong>function googlefonts() {
?><link href='http://fonts.googleapis.com/css?family=Source+Code+Pro' rel='stylesheet' type='text/css'><?php
}
add_action('wp_head', 'googlefonts');?></strong>

I then call the function in my childthemes CSS file.

However,although the font is called up correctly it seems to cause a few issues as I get the following message when I go to my dashboard or attempt to log out.

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /homepages/37/d212414563/htdocs/blog/wp-content/themes/twentyelevencustomchild/functions.php:32)

It also seems that this method is causing the plugins to have some issues too.

My question is I guess,what is the best way to approach this?


Viewing all articles
Browse latest Browse all 135067


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>