I have a javascript method which is receiving a UTF-8 encoded string (ViewBag.errorText), and uses this as a parameter to a new function.
The problem is that the text displayed in show_error_dialog is displaying the html escaped characters (æø etc') and not the intended ("æåø" etc.).
I presume the problem is the enclosed <text> tags but can't seem to get around this.
<script type="text/javascript" charset="utf-8">
function performLoadOperations() {
@if(ViewBag.errorText!= null) {
<text>show_error_dialog('@ViewBag.errorText');</text>
}
}
</script>