The html text following:

```
&lt;script type=&#34;text/javascript&#34;&gt;alert(123);&lt;/script&gt;
<script>alert(123);</script>

```

As mentioned above, only part of html text was escaped.

Now, I want to escape the text: **`<script>alert(123);</script>`**.

Expected result:

```
&lt;script type=&#34;text/javascript&#34;&gt;alert(123);&lt;/script&gt;
&lt;script&gt;alert(123);&lt;/script&gt;

```

I need some help.