Php photo gallery TWG | JFUploader | TWG Flash upload | WFU | Forum

Get help for TinyWebGallery, the best image gallery. The forum is also home for the Joomla JFUploader, TWG Flash Uploader and the Wordpress flash uploader.
It is currently 28. Mar 2024, 18:24

This forum is readonly now. Please use the new forum if you don't find the answer to your question here. The new forum is at https://www.tinywebgallery.com/blog/forum/


All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 10 posts ] 
Author Message
PostPosted: 30. Jan 2019, 17:29 
Offline

Joined: 18. Nov 2018, 21:40
Posts: 50
I am including an iframe and it shows up ok on first load. I have a table at the bottom (jquery DataTable) and when I click on a row I replace the content of the top DIV. The problem is that when the top DIVs content is replace, the table and everything under is hidden. In the source code it it is there but I can not see it anymore. Seems the IFRAME is collapsed. Is there any way I can fix this?

Here is my page: https://biofokus.no/narin2/ and if one clicks on a table row, the page collapses.


Top
 Profile  
 
PostPosted: 30. Jan 2019, 18:28 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
you get errors in the iframe:

The configuration of "resize_on_element_resize" is invalid. The specified element #frame-content could not be found. Please check your configuration. If your content is loaded dynamically please specify onload_resize_delay with a time that is longer then your content needs to load!
3ai_external.js?vs=38:594 The configuration of "element_to_measure" is invalid. The specified element frame-content could not be found. Please check your configuration. As fallback "default" is used which measures the first child of the body.

can you please first not use this feature! because it seems this is my testdata #frame-content

remove #frame-content from the resize on element resize in the administration and save again.
The try #ai_wrapper_div
This is my wrapper which was added. So this is in the page ;).

So first make sure that this does not happen because of the ajax in the iframe...

Best, Michael


Top
 Profile  
 
PostPosted: 30. Jan 2019, 22:58 
Offline

Joined: 18. Nov 2018, 21:40
Posts: 50
Thanks Michael!

First I went through the page and checked every single tag, specially the <DIV> tags if they were closed. Sure enough my top DIV that I replace content with ajax was not closed properly. So that at least made the ajax load work without cutting the page. I must have removed the specific DIV "frame-content" so I saw in the Chrome console that it was complaining it was missing.

Then I tried your suggestion removing it from administration and then adding #ai_wrapper_div in administration. Everything seems to work fine now, also on ajax resize in the frame.

Does this code look correct now for the iframe shortcode?

Code:
[advanced_iframe use_shortcode_attributes_only="true" src="https://narin.biofokus.no/indexbio_sa.lasso" id="narinbio" enable_responsive_iframe="true" enable_external_height_workaround="true" width="100%" height="800" url_forward_parameter="ALL" add_iframe_url_as_param="remote" resize_on_element_resize="ai_wrapper_div" enable_ios_mobile_scolling="false" scrolling="no"]


Thanks again Michael for your fast reply and great help!


Top
 Profile  
 
PostPosted: 30. Jan 2019, 23:34 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
you can remove resize_on_element_resize="ai_wrapper_div" enable_ios_mobile_scolling="false" from the shortcode.
resize_on_element_resize is for the same domain but not used because you have set enable_external_height_workaround="true".
And enable_ios_mobile_scolling="false" is the default.

Best, Michael


Top
 Profile  
 
PostPosted: 31. Jan 2019, 14:17 
Offline

Joined: 18. Nov 2018, 21:40
Posts: 50
Thanks. When I removed the "element_to_measure" value I get this error lots of times in console. Is it working or is this just an error I can ignore?

Code:
The configuration of "element_to_measure" is invalid. The specified element  could not be found. Please check your configuration. As fallback "default" is used which measures the first child of the body.


Top
 Profile  
 
PostPosted: 31. Jan 2019, 19:09 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
this is not good. What have you set at element to measure? normally default is not the worst idea...


Top
 Profile  
 
PostPosted: 31. Jan 2019, 21:28 
Offline

Joined: 18. Nov 2018, 21:40
Posts: 50
You mean to leave element to measure blank? I tried this and that is when I get the error message.


Top
 Profile  
 
PostPosted: 1. Feb 2019, 00:00 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
no - "default" is the default. so simply use this.

Best, Michael


Top
 Profile  
 
PostPosted: 1. Feb 2019, 16:09 
Offline

Joined: 18. Nov 2018, 21:40
Posts: 50
I entered "default" in the "element to measure" field in administration. It seems it stopped complaining now.

But I wonder if something is wrong with my config since in Chrome console I get a 404-Not Found for this file:

https://narin.biofokus.no/wp-content/plugins/advanced-iframe/js/iframe_height.html?height=1318&width=1026&id=narinbio&loc=https%3A%2F%2Fnarin.biofokus.no%2Findexbio_sa.lasso

This file should be on the parent site, not the iframe site right?

I see a file iframe_height.html in the plugin folder on parent site. Why is it looking for this file on the iframe site?

When I do an ajax call inside the iframe (e.g. show more table rows or expand a div so the height increases) the iframe does not expand in height.


Top
 Profile  
 
PostPosted: 2. Feb 2019, 13:50 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
This is the file that is actually "receiving" the height info and all other stuff.

https://narin.biofokus.no/wp-content/plugins/advanced-iframe/js/iframe_height.html is missing. Maybe your serer disallows this.
This is the reason why auto height does not work. You should switch to post message communication. See the external workaround tab. Change this there to "debug"! Then you see in the browser console this data.
This is actually the default since a while. Have you installed the free version before? Because there this is the default there...

Best, Michael


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Bing [Bot] and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron
powered by phpbb | Datenschutz/ Privacy policy