I want characters like \'ø\' to be printed directly, but in the source \'ø\' shows up as ø
If the output goes through Html.Encode()
AFAIK this is not possible unless you roll your own custom HTML encoding routine (which I absolutely would recommend you against).
The resulting HTML is correct and the character is properly displayed on the client browser. HTML is meant to be read by programs (web browsers) in order to present it to a human readable form, not by humans.
- Støvletter
is a perfectly valid HTML that will be displayed like this on the client browser: