Support ForumIframe on fancybox – Support Forum https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/feed/ Mon, 06 May 2024 11:43:50 +0200 http://bbpress.org/?v=2.5.12-6148 en-US https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3648 <![CDATA[Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3648 Wed, 16 Jul 2014 21:37:49 +0000 lvmaster Is there a way so I can open an Iframe (contact form or other html) inside the Fancybox?!

I already tried using this(extracted from the Fancybox site) with no success.
<a href="/demo/iframe.html">Iframe</a>

And I saw that when you calls an image with Fancybox it uses “class=openfancybox-image”, different than the original sentence from Fancybox site “class=”fancybox”, can you explain me a little?!

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3658 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3658 Thu, 17 Jul 2014 05:21:03 +0000 IshYoBoy Hi Ivmaster,

Yes, we use class “openfancybox-image” to avoid collisions with other plugins which might be using the default fancybox classes.

The link regarding the iframe seems to be broken. Could you please double-check it please?

Doesn’t it work if you create a link containing the class “openfancybox-image” and in the “href” attribute a link to the HTML file that needs to be opened?

Please provide the code you are trying to use exactly. You can use the “CODE” button in this editor in order to wrap the code.

Cheers

A 5 star rating is always a great motivation for us if you are happy with our theme or support!
Themeforest | MojoMarketplace | Creative Market

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3664 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3664 Thu, 17 Jul 2014 11:30:46 +0000 lvmaster Hehe, the links isn’t broken, it’s just because what you said, I haven’t used the “CODE” button, sorry.

The code I tried was: <a class="various" data-fancybox-type="iframe" href="/demo/iframe.html">Iframe</a>

But it didn’t worked to! I tried what you said about usign the class “openfancybox-image” inside the link and I came with this: <a class="“openfancybox-image" href="https://mysite/iframe.html">Iframe Teste</a>

But it keeps opening in a new page.

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3666 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3666 Thu, 17 Jul 2014 14:54:35 +0000 IshYoBoy Hey,

just checked the code above. Seems like there are double quotes in it and one of them are not even regular quotes. Try this:

<a class="openfancybox-image" href="https://mysite/iframe.html">Iframe Teste</a>

Also could you provide a link where we could see it implemented? Thanks

Cheers

A 5 star rating is always a great motivation for us if you are happy with our theme or support!
Themeforest | MojoMarketplace | Creative Market

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3669 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3669 Thu, 17 Jul 2014 15:44:45 +0000 lvmaster https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3695 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3695 Fri, 18 Jul 2014 20:40:52 +0000 lvmaster Could you see whats going on?!

I sort of managed to do by adding this code:
<a class="openfancybox-image" href="/newsletter.html" data-fancybox-type="iframe">Iframe</a>

But then the iframe width and height goes weird, how can I set them on my stylesheet?!

Thanks.

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3720 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3720 Mon, 21 Jul 2014 09:31:21 +0000 IshYoBoy Hi Ivmaster,

Maybe it will be better not to use the “openfancybox-image” class but to add your custom one and them add javascript code which would setup fancybox for this class but it would also set the exact dimensionz. Maybe check this topic
https://stackoverflow.com/questions/2464870/fancybox-iframe-dimension

E.g.:

HTML:
<a class="my-iframe-link" href="/newsletter.html" data-fancybox-type="iframe">Iframe</a>

JavaScript:

The JavaScript code can be added either via child theme or using the “Raw JS” element on the exact page where the iframe is used.

Cheers

A 5 star rating is always a great motivation for us if you are happy with our theme or support!
Themeforest | MojoMarketplace | Creative Market

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3728 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3728 Mon, 21 Jul 2014 15:14:52 +0000 lvmaster I’m struggling to put it on my child theme, but I’m not familiar to javascript!!!

I tried creating a js folder with the following code:

And this on the functions.php to call the script:

But it’s not working.
Would you show me the path to do it?!

]]>
https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3735 <![CDATA[Reply To: Iframe on fancybox]]> https://support.ishyoboy.com/forums/topic/iframe-on-fancybox/#post-3735 Tue, 22 Jul 2014 05:17:12 +0000 IshYoBoy Hey Ivmaster,

You need to do the following steps:

1. Create a javascript file in your child theme. E.g. “my-custom.js”

2. Enqueue this file in the right time. Add this function to your child theme’s functions.php file:

3. Make sure the “my-custom.js” file is in the correct path you are using in wp_regiter_script function an so “/assets/js/my-custom.js”.

4. Add the jQuery functionality to it:

This is the right way to do it.

Cheers

A 5 star rating is always a great motivation for us if you are happy with our theme or support!
Themeforest | MojoMarketplace | Creative Market

]]>