Title: Iframe script dosn&#8217;t work under &#8220;proxy&#8221;
Last modified: September 14, 2017

---

# Iframe script dosn’t work under “proxy”

 *  Resolved [roycegracie](https://wordpress.org/support/users/roycegracie/)
 * (@roycegracie)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/iframe-script-dosnt-work-under-proxy/)
 * this is the site i try to make faster:
    [https://developers.google.com/speed/pagespeed/insights/?url=http%3A%2F%2Fwww.agada4u.co.il%2F&tab=desktop](https://developers.google.com/speed/pagespeed/insights/?url=http%3A%2F%2Fwww.agada4u.co.il%2F&tab=desktop)
 * under “Leverage browser caching” you can see there is a script named :
    “ad_status.
   js”, this script is coming from a youtube API that is installed on the theme,
   it’s not coming from the youtube iframe (i gave all the iframes a LAZY LOAD)
 * therefore, i have found this script inside my theme:
    [https://www.youtube.com/iframe_api](https://www.youtube.com/iframe_api)
 * i have moved the url :
    youtube.com/iframe_api
 * under “Proxy Scripts” in the tab “proxy” tab. but this still dosn’t disable the
   google page speed error
 * any ideas on how to fix this ?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [optimalisatie](https://wordpress.org/support/users/optimalisatie/)
 * (@optimalisatie)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/iframe-script-dosnt-work-under-proxy/#post-9504578)
 * Hi Roycegracie,
 * The plugin is not able to modify the contents of an iframe, however, it does 
   provide a lazy script loading feature that makes it possible to hide scripts 
   and iframes that are located below the fold.
 * The option is located on the Javascript Optimization tab (`Lazy Load Scripts`).
 * For example, to load a YouTube video when the user scrolls it in view, you could
   use the following code.
 * <div data-lazy-widget><!–
    <iframe allowfullscreen=”” frameborder=”0″ height=”
   315″ src=”[http://www.youtube.com/embed/UkWd0azv3fQ#t=2m30s&#8221](http://www.youtube.com/embed/UkWd0azv3fQ#t=2m30s&#8221);
   width=”420″></iframe> –></div>
 * If you need to load a video in the above the fold view then the only option is
   to optimize the video itself. For example, if you just need to display the preview
   image until the user clicks the play button, you could convert the iframe to 
   a image that replaces itself with the iframe embed code when the user clicks 
   on it. There may be other solutions.
 *  Thread Starter [roycegracie](https://wordpress.org/support/users/roycegracie/)
 * (@roycegracie)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/iframe-script-dosnt-work-under-proxy/#post-9505684)
 * hello ! i have found my solution here:
    [https://www.labnol.org/internet/light-youtube-embeds/27941/](https://www.labnol.org/internet/light-youtube-embeds/27941/)
 * thank you again for this very good plugin !

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Iframe script dosn’t work under “proxy”’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/above-the-fold-optimization_fcfbf6.
   svg)
 * [Page Speed Optimization](https://wordpress.org/plugins/above-the-fold-optimization/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/above-the-fold-optimization/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/above-the-fold-optimization/)
 * [Active Topics](https://wordpress.org/support/plugin/above-the-fold-optimization/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/above-the-fold-optimization/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/above-the-fold-optimization/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [roycegracie](https://wordpress.org/support/users/roycegracie/)
 * Last activity: [8 years, 6 months ago](https://wordpress.org/support/topic/iframe-script-dosnt-work-under-proxy/#post-9505684)
 * Status: resolved