Can't add add link to head in iframe because of cross-origin error, but apparently works in Chrome
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
People
(Reporter: hosein.danesh20, Unassigned, NeedInfo)
Details
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:65.0) Gecko/20100101 Firefox/65.0
Steps to reproduce:
hi , sry im so confiused because of this problem !
iframe , iframe , iframe !! my bad dream every night :))
problem :
how i can add some link tag(contains css file) to head of iframe tag !
i search so much . all says u cant access to iframe head because of cross origin policy !! but i can access in chrome ! (in chrome we can access to iframe everything , wait wait , this is true for iframes that have not src (behavoir like a div tag !) , if that iframe have src attr contains some domain link , here cross origin policy worked and you cant access to iframe contens right now !)
I hope that I will explain well this problem !
please fix it ...
some developers need this so much .
i hope mozilla help us .
Actual results:
when i add some link tag to head of iframe it dosnt work !
(in chrome its work on iframes that has not src attribute , and when it has src attr you cant access to iframe contents)
Expected results:
i hope to fixed this problem
and What should have happened?
when we add link tag to head of iframe :
- it must not worked in iframes that have src attr(contains some address)
- it must work in iframes that have not src attr (behavoir like a div tag !)
Comment 1•6 years ago
|
||
Hi @Hosein danesh, If you can provide a scenario, test-case or something related to test your problem it will be great, if not I guess the dev's team can handle further the problem.
Thanks for your contribution.
Comment 2•6 years ago
|
||
Can you add a test-case that repros the issue, or an example of which domains are involved and how the iframe is created or what not? Otherwise this is not really actionable.
Also, ensure you're waiting for the iframe to load properly? Otherwise you may accidentally add the link to about:blank
.
Assignee | ||
Updated•6 years ago
|
Comment 3•6 years ago
|
||
It's hard for us to move on without a simple test case.
Dear reporter, please feel free to reopen when you have a chance to get back here with the kind test case mentioned in comment 2. :)
Description
•