Bill: How to remove WordPress login wp_footer, wp_head self-loading open sans fonts, fonts.googleapis.com connection causes the problem of card death

Source: Internet
Author: User
Tags wordpress login

sometimes in the view of their own WordPress site when found that the webpage is not responding for a long time, the card is connected to fonts.googleapis.com as shown in:

When viewing the source of the Web page, I found the following code in the head:

<relid= ' open-sans-css '  hreftype  media  />  

This code indicates that the current Web page is connected to the Google Font server, the card is "connecting to fonts.googleapis.com", it is possible that the current network is unable to access the server or relatively slow.

Workaround:

Add the following code to the functions.php :

 add_filter (' Gettext_with_context ', ' Disable_open_sans ', 888, 4 function  Disable_open_sans ($ Translations ,  $text ,  $context ,  if  (' Open Sans font:on or off ' = =  $context  && ' on ' = =  $text    $translations  = ' off ' ; }  return   $translations   

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.