Basically the same thing as
<https://www.w3schools.com/tags/tryit.asp?filename=tryhtml5_ev_onkeyup>

But I am getting this error for some reason.

HTML

```
<nb-card>
  <nb-card-header>
    Enter your name: 
  </nb-card-header>
  <nb-card-body>
    <input type="text" id="fname" onkeyup="myFunction()">
  </nb-card-body>
  <script>
    function myFunction() {
      var x = document.getElementById("fname");
      x.value = x.value.toUpperCase();
    }
    </script>
</nb-card>

```

![Error](https://i.stack.imgur.com/f5zCh.png)
![Nb Card](https://i.stack.imgur.com/Bhm9o.png)

Same error without the nebular library:
HTML

```
<html>
<body>
  Enter your name: 
  <input type="text" id="fname" onkeyup="myFunction()">

  <script>
    function myFunction() {
      var x = document.getElementById("fname");
      x.value = x.value.toUpperCase();
    }
  </script>
</body>
</html>

```

Does anyone know why? Thanks.

I have tried many other stack overflow solutions and they do not work. I am hoping to not use JQuery. This should have worked but it doesn't. I follow the other W3 School examples and get the same error.