Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
188
rated 0 times [  192] [ 4]  / answers: 1 / hits: 28352  / 10 Years ago, thu, march 20, 2014, 12:00:00

I know it's a security issue. But is there any way in HTML5. Cause I seen the below code opens a window with the parents URL in tweet box



<iframe src=https://platform.twitter.com/widgets/tweet_button.html
style=border: 0; width:130px; height:20px;></iframe>

More From » html

 Answers
22

Try this inside the iframe. It will alert the parent window's location URL.



alert(document.referrer);

[#71894] Tuesday, March 18, 2014, 10 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
dequant

Total Points: 88
Total Questions: 99
Total Answers: 95

Location: Ukraine
Member since Sun, Dec 13, 2020
4 Years ago
dequant questions
;