Support » Plugin: LiteSpeed Cache » Browser Caching Pagespeed Warning using Contact Form 7

  • Resolved jscrm


    I have a contact form (powdered by the Contact Form 7 plugin) on a website.

    When running PageSpeed Insights, I get near perfect score but a warning is shown:

    Leverage browser caching for: (expiration not specified)

    I have the Browser Cache option enabled on LSCache plugin. Is this the expected behaviour? Would it be possible to add browser cache to this request to achieve perfect score? 😉

    Report number: GMFRMXES

    • This topic was modified 4 years, 6 months ago by jscrm.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Hai Zheng⚡


    LOL I don’t think so as that refill action is done by CF7 by purpose. With browser cached it, it can’t hit PHP anymore. However, you can try to contact CF7 to see if it’s possible or not.



    I have found the solution to fix this, go to Contact Form 7 Plugin Directory and then open JS folder inside that you will find file called scripts.js edit the file and find following code (line 35 to 37)

    if ( wpcf7.cached ) { wpcf7.refill( $form );}

    Edit this code to the following

    if ( wpcf7.cached ) { wpcf7.cached = 0;}

    or comment the code

    Issue fixed.

    Sachin G.

    thank u @sachinghare

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Browser Caching Pagespeed Warning using Contact Form 7’ is closed to new replies.