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

Using Advanced iframe on a non-wp site
https://www.tinywebgallery.com/forum/viewtopic.php?f=21&t=6734
Page 1 of 1

Author:  xega [ 17. Mar 2020, 20:29 ]
Post subject:  Using Advanced iframe on a non-wp site

Hi!
Is it possible to use Advanced Iframe on a non-WP site? I have WP pages that I need to embed into a different CMS (a genealogy program), but can Advanced Iframe be used in such a case?
Best regards
Rakel

Author:  TinyWebGallery [ 17. Mar 2020, 22:13 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Sure,

there are 2 ways.

- Using the standalone version. http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-standalone
- Using the plugin on the page in the iframe. See http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/share-content-from-your-domain-add-ai_external-js-local

Best, Michael

Author:  xega [ 18. Mar 2020, 17:02 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hello again, and thank you for your reply!
If I use the standalone version, can I have several (dozens) of pages that use advanced iframe? Or just one?

If I use the standalone version, should I upload the entire folder that I downloaded from Envato or just the standalone folder? I downloaded "All files and documents".
Thanks again!

Author:  TinyWebGallery [ 18. Mar 2020, 21:16 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hi,

you need all files. The standalone folder is only the wrapper. You need to get the folder structure right once and then you are fine. see my example page for details.

But what is your setup? do you want to share the same webpage on many pages?

Because then the other example is maybe the better option for you. Because then you install it once on the wp site and on the other pages are only an javascript and a simple iframe.
Of you use the standalone version you need to install it everywhere (and also need a license for each domain!). but this is more powerful as you can use all features.

So the basic question is: which features do you use?

Best, Michael

Author:  xega [ 18. Mar 2020, 21:52 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hello again :)
I have a genealogy website (http://www.legstadaleit.com) and since it does have limitations I have decided to create WP pages that I will integrate into my genealogy site. I will have several different pages, in the beginning only a few but hopefully in time a lot (like several dozens, maybe more).

I used to use advanced iframe on my wp site, when I used WP as a frame for my genealogy site, but now I have switched it around (using the genealogy software primarily). I didn't initially think I could use advanced iframe since I was no longer using WP as a primary CMS, but then I remembered it and thought I should check it since it is way superior to just using a basic iframe.

You can see an example of a page where I was attempting to use the basic iframe (couldn't get it to work properly) here: https://www.legstadaleit.com/listar/kennarartest.php. The header and footer are from the genealogy CMS but the table is made in WP using Tablepress.

What would you recommend for me? I only have this one domain and the simpler the setup the better.
Best regards
Rakel

Author:  TinyWebGallery [ 19. Mar 2020, 22:54 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Which features do you like to use?
if you use auto height I would recommend you use the 2nd link I send you. Then you have only to include a small javascript + an iframe.

If you like/need lazy load, a loading indicator you need to go with the 1st link I sent you.

Best, Michael

Author:  xega [ 20. Mar 2020, 17:52 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Sorry for being so slow but doesn't link nr. 2 assume that I am sharing a WP page ON a WP page? See this sentence:
Quote:
You can include ai_external.js to your page by selecting 'Yes' at "Options -> Add ai_external.js local"


How do I do this when I am trying to share a WP page in a non-WP page? Do I have to install the Advanced iframe plugin in the WP site to get this to work and then also include a script in the Non-WP site?

Author:  TinyWebGallery [ 20. Mar 2020, 23:21 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

No. Please check the example again!

"You can include ai_external.js to your page by selecting 'Yes' at "Options -> Add ai_external.js local""
-> This adds the ai_external.js to your WP site which is IN the iframe!

You install the plugin to your wordpress page. And in the non WP site you include the stuff written in the example: One Javascript and one iframe. So 2 lines.

Best, Michael

Author:  xega [ 21. Mar 2020, 21:30 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Got it!
If I want to have the height set automatically based on content, do I do that in the iframe code on the non-wp site? I tried setting
"Resize iframe to content height" to "Yes" but that didn't help.
"Support WP multisite" is set to "Yes" and my code is:
Code:
<script src="https://www.legstadaleit.com/wp/wp-content/plugins/advanced-iframe/js/ai_resize.js"></script>
<iframe id="iframe-advanced_iframe" src="https://legstadaleit.com/wp/skipsskadar/" width="100%" style="visibility:hidden"></iframe>


The page I am testing on is here: https://legstadaleit.com/listar/kennarartest2.php

Thanks!
Rakel

Author:  TinyWebGallery [ 22. Mar 2020, 00:17 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hi,

I don't understand. I see the height working. The postMessage is sent and the height is set.
You can set postMessage to debug. Then you see it in the console log.

You can set the border to none of the iframe - would look better ;). It is set to 2 px in your page.

Best, Michael

Author:  xega [ 22. Mar 2020, 16:45 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Ah I see, it was probably because of the pagination on the table. The second page in the pagination did not resize the window. But I have removed the pagination so that should be ok. I have also removed the frame as you suggested :-)

However I have another question, hopefully the last one. If you click on a name in the link I sent before: https://legstadaleit.com/listar/kennarartest2.php, the link opens a new page inside the iframe, so the header and footer is also included. Is it possible to fix this? The page structure should look like this: https://www.legstadaleit.com/getperson.php?personID=I7091&tree=Tree2

Thanks in advance!
Rakel

Author:  TinyWebGallery [ 22. Mar 2020, 22:28 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hi, sure

For the pagination: see this
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/resize-on-element-resize#e27
if after the page load the iframe height changes this is the way to solve it.

You can hide elements in the iframe ;). See:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/external-workaround-with-post-message

See: var iframe_hide_elements

so hiding header footer is no problem. Your page has not many unique ids. So adding them would make sense ;).
Or use: https://www.w3schools.com/cssref/sel_nth-child.asp

Best, Michael

Author:  xega [ 23. Mar 2020, 19:14 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hello again
I am afraid this is getting too complicated for me :( How much do you charge if you fix this for me?
Best regards
Rakel

Author:  TinyWebGallery [ 24. Mar 2020, 21:28 ]
Post subject:  Re: Using Advanced iframe on a non-wp site

Hi - please contact me by e-mail.
http://www.tinywebgallery.com/en/about.php

Best, Michael

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