[英]JavaScript - how can i execute a function of iframe, from main page?
[英]How can I share a token variable from my main page to iframe other than using a post message?
我需要知道如何在iframe中共享父窗口中的變量。
我的情況是這樣的
我有2個angular5應用程序,說A和B。
B作為Iframe加載到A。
身份驗證在A中完成,我獲得了訪問令牌,該令牌需要傳遞給B。
這些是我嘗試過的。
您可以將open B iframe與auth令牌一起用作查詢參數:
<iframe src="yourURL?auth_token=ASDF1234"></iframe>
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.