[Resolved] rel=preload for 3rd party plugin not working

Home Forums Support rel=preload for 3rd party plugin not working

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1490886
    Andrew

    Google PageSpeed Insights suggests I preload a font from a lightweight social icons plugin.

    Following guidance found on this forum I created a Hook element in wp_head across the entire site with the code:

    <link rel=”preload” href=”/wp-content/plugins/lightweight-social-icons/fonts/fontello.woff″ as=”font” type=”font/woff2″ crossorigin>

    For some reason it doesn’t seem to do anything – PageSpeed keeps providing the same advice about preload even with this script, suggesting the script isn’t working.

    Any ideas if I have done something wrong?

    Thanks

    #1491553
    David
    Staff
    Customer Support

    Hi there,

    can you share a link so i can take a look?

    #1491567
    Andrew

    Of course, sorry, should have done that initially. It’s https://tarsolutions.co.uk

    Please advise if you need access to the back end.

    #1491657
    David
    Staff
    Customer Support

    Try updating the URL in your pre-load link to include the full address ie.

    https://tarsolutions.co.uk/wp-content/plugins/lightweight-social-icons/fonts/fontello.woff

    #1491852
    Andrew

    For some reason it doesn’t seem to work. The tag does appear in the head section of the site but for whatever reason doesn’t seem to do very much.

    #1491901
    David
    Staff
    Customer Support

    I am not seeing the full URL in the link tag ?

    #1492112
    Andrew

    I’ve got it. Something stupid actually so apologies for the time waste. I copied the initial code and altered the URL. But the copy paste produced dodgy quotation marks. Now fixed. Thanks for your time and assistance.

    View post on imgur.com

    #1492181
    David
    Staff
    Customer Support

    Yeah curly quotes are a pain … glad to hear you got it resolved (?)

    #1492187
    Andrew

    Yes, all sorted. Thanks for your time, you certainly helped push me in the right direction.

    #1492193
    David
    Staff
    Customer Support
Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.