D
D
Dymok2019-11-08 21:49:09
JavaScript
Dymok, 2019-11-08 21:49:09

How to access fancybox popup content in callback?

A simple example
When opening a popup, you need to get its contents (in this case div.popup#popup,
5dc5b861ea5b3237694568.jpeg

console.log(current["$content"]);
//или так
console.log(current.$content);

only undefined is obtained.
What can be wrong?

codepen

Answer the question

In order to leave comments, you need to log in

1 answer(s)
0
0xD34F, 2019-11-08
@UnluckySerivelha

change beforeShow to afterShow

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question