Php photo gallery TWG | JFUploader | TWG Flash upload | WFU | Forum
https://www.tinywebgallery.com/forum/

External Workaround Auto Height Issue
https://www.tinywebgallery.com/forum/viewtopic.php?f=21&t=4333
Page 1 of 1

Author:  xahid [ 31. May 2017, 03:25 ]
Post subject:  External Workaround Auto Height Issue

I have tried to give this plugin a chance a few times in the past couple of years, but I have not been successful. I am trying to use the external workaround method, and it actually works fine when I am logged into wordpress, but when I logout of wordpress, the auto height goes away and starts to show the scrollbar again.

I have tried deactivating all other plugins and clearing the cache to make sure if there might be a plugin that was causing the problem, but that did not help either.

I am using a wildcard SSL on both the wordpress site and the external site (iframe source) which is simply on a subdomain of the main wordpress site.

This is the WP site where Advanced Iframe Pro is installed, here is an example of one of the pages where I am trying to put an iframe: https://www.sinium.com/seo/alexa-rank-checker/

This is the iframe source page: https://seo.sinium.com/alexa-rank-checker

I have tried different shortcode variations without success, this is my current shortcode settings:
Code:
[advanced_iframe securitykey="hidden" use_shortcode_attributes_only="true" src="https://seo.sinium.com/alexa-rank-checker/" width="100%" scrolling="auto" id="advanced_iframe" name="alexa" show_iframe_loader="true" enable_responsive_iframe="true" onload_resize="true" store_height_in_cookie="true" resize_on_ajax_jquery="false" add_document_domain="true" enable_external_height_workaround="true" ]


and this is located in the header of the source page:
Code:
<script src="https://www.sinium.com/wp-content/plugins/advanced-iframe/js/ai_external.js"></script>


Again, the auto height works fine when I am logged into wp as an admin, but when I logout, the auto height disappears the the scrollbar shows on all browsers.

What am I doing wrong?

Author:  TinyWebGallery [ 31. May 2017, 09:46 ]
Post subject:  Re: External Workaround Auto Height Issue

Hi. It seems
https://www.sinium.com/wp-content/plugins/advanced-iframe/js/ai_external.js

cannot be found! Can ou check the path?

Also your shortcode seems to be a mixture of the external workaround.
You either should use the solution if you are on a subdomain OR the ai_external.js.

In you case as there is a problem to find the ai_external.js you should only do the sub domain version.

Add
<script>document.domain='sinium.com';</script>
to your page and not the ai_external.js.


[advanced_iframe securitykey="hidden" use_shortcode_attributes_only="true" src="https://seo.sinium.com/alexa-rank-checker/" width="100%" id="advanced_iframe" name="alexa" show_iframe_loader="true" enable_responsive_iframe="true" onload_resize="true" add_document_domain="true" document_domain="sinium.com"]

if you only have one iframe or all iframes have the same configuration you can also do all the settings in the administration and only use [advanced_iframe securitykey="hidden"].

See http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/sub-domain-auto-height-and-css-modifications for a working example of this solution.

Best, Michael

Page 1 of 1 All times are UTC + 1 hour [ DST ]
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/