I have a simple form where you can upload html files. I have 3 files:

* Main HTML file - which contains my form and JavaScript function.
* Secondary HTML file - this is used to upload to the form.
* CSS file - this is for the secondary HTML file.

I want to override the CSS value of the uploaded html file using this function in my main HTML file:

```
<!DOCTYPE html>
<html>
<head>>
<meta charset="UTF-8">
<title>Changing the style of another HTML File</title>

<script type="text/javascript">
function updateSize() {
  var nBytes = 0,
      oFiles = document.getElementById("uploadInput").files,
      nFiles = oFiles.length;
  for (var nFileId = 0; nFileId < nFiles; nFileId++) {
    nBytes += oFiles[nFileId].size;
  }
  var sOutput = nBytes + " bytes";
  // optional code for multiples approximation
  for (var aMultiples = ["KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB"], nMultiple = 0, nApprox = nBytes / 1024; nApprox > 1; nApprox /= 1024, nMultiple++) {
    sOutput = nApprox.toFixed(3) + " " + aMultiples[nMultiple] + " (" + nBytes + " bytes)";
  }
  // end of optional code
  document.getElementById("fileNum").innerHTML = nFiles;
  document.getElementById("fileSize").innerHTML = sOutput;
}

function extract() {
var el = document.getElementById("test");
el.style.background = 'green';
el.style.color = 'red';
}
</script>

<body onload="updateSize();">
<form>
<p><input id="uploadInput" type="file" name="myFiles" onchange="updateSize();" multiple> selected files: <span id="fileNum">0</span>; total size: <span id="fileSize">0</span></p>
<p><input type="button" value="Submit" onclick="extract()"></p>
</form>
</body>
</html>

```

The Secondary HTML file has the following code (This will be submitted to the form): 

```
<html>
<head>
<link rel="stylesheet" type="text/css" href="test.css" />
</head> 
<body> 
<div id="test">This is a div</div>
</body> 
</html> 

```

This is my CSS file for my Secondary HTML file:

```
#test {
background-color: red;
color: yellow;
};

```

However, it doesn't work. Where I'm I going wrong?