My HTML page consists of multiple iframes, each linking to a text file on the same domain.
I have done some research on how iframes behave when they point to an HTML file, but I haven't found much information on what happens when they link to a text file. Also, it's not possible to add styling directly inside the text files themselves.
The interesting part is that the text content of the iframe inherits the background color of the parent element, but not the text color.
When I apply the following CSS in the parent HTML document, the background color of the iframe content changes accordingly:
iframe
{
background-color: black;
}
However, when I try to change the text color of the iframe content using the code below, it doesn't work:
iframe
{
color: white;
}
Why does this happen?