1

when i call <%= Html.ActionLink("abcáí", "Index") %> in my view, it generates this html output: <a href="/">abc&#225;&#237;</a>

but I need not to escape the foreign characters áí, so I want the output to be <a href="/">abcáí</a>

My problem is not only with the function ActionLink, but everywhere, where is the htmlencoding used.

Any suggestions?

tereško
  • 58,060
  • 25
  • 98
  • 150
Petr
  • 11
  • 2
  • When using equels to write content to the page, html encoding is not used. Only when using Html.Encode or a colon in place of the equels, is html encoding used. – Jamie Dixon Jun 12 '11 at 14:26
  • Jamie: No, the function Html.ActionLink always html encode the linkText attribute – Petr Jun 12 '11 at 14:31

1 Answers1

0

That's totally not something you should be worried about. The HTML helpers correctly HTML encode the output. The output is intended to be read by browsers, not humans. And since this output is correctly formatted, those browsers will correctly display the content to the humans using them.

Darin Dimitrov
  • 1,023,142
  • 271
  • 3,287
  • 2,928