-1
Like this: I put a js script inside a div, for example. How can I make this script identify the DIV in which it is contained without selectors like ID or Class?
It’s just that I see some embed scripts that insert things (images, videos, etc.) into the element in which they are placed, without using selectors. How is it done?
NOTE: Javascript pure. I’m learning pure js.
Thank you and good afternoon to all.
But the div has an ID ?
– MagicHat
Can you give an example of the code you refer to to to understand better what you refer to? "I see some embed scripts that insert things [...] inside the element in which they are placed"
– Sergio