-1

I'm using fancybox 3, but I ran into the problem, I can not either understand how to display the name in the opened iframe. Nowhere about this information have not found. . I do so.

<a data-fancybox data-type="iframe" data-title="name iframe" title="name iframe" data-src="http://totaldict.ru/dictants/gorod-na-reke/" href="javascript:;">
    External page
</a>

$("[data-fancybox]").fancybox({
toolbar: false,
smallBtn: true,
autoSize: true,
helpers: {
    title: {
        type: 'inside'
    },
    buttons: {}
},
iframe: {
    css: {
        width: '700px'
    }
},
});

What am I not so prescribed?

Daniel B
  • 3,109
  • 2
  • 33
  • 42
gheka
  • 3
  • 1

1 Answers1

0
iframe : { 
    attr : {
        title : 'myTitle'
    } 
}
Janis
  • 8,593
  • 1
  • 21
  • 27
  • does not work, here's an example link. https://codepen.io/gheka/pen/ypgGeG – gheka Dec 27 '17 at 11:08
  • You have provided perfectly working demo. The generated iframe tag contains `title="myTitle"` attribute. So, if this is not what you were looking for, I guess I do not understand your question. – Janis Dec 27 '17 at 14:46
  • Sorry, I'm wrong to put it. For clarity, I attached 2 photos, they can see what I meant. Noted by rat rectangles. 1 photos - https://ibb.co/hV3QSG 2 photos - https://ibb.co/k24ogb – gheka Dec 27 '17 at 23:34
  • Sorry, this is not implemented in v3 (main reason is that these caption types would look weird while swiping and zooming). You can try to redesign (for example - https://codepen.io/anon/pen/wpJdeZ), but it will not work the same, because caption in v3 is not directly under the content. – Janis Dec 28 '17 at 10:02