简体   繁体   English

我必须为`→`使用@ Html.ActionLink helper方法提供一个向右的尾箭头做什么?

[英]What must I do for `→` to give a trailing right arrow with the @Html.ActionLink helper method?

I am wondering why the follow code to create a hyperlink does not give me a trailing right arrow. 我想知道为什么以下创建超链接的代码没有给我尾随右箭头。 What must I do for " →" 我该怎么办" →" to give a trailing arrow? 给出后退箭头?

@Html.ActionLink(
    String.Concat("leading ", viewModel.Text.ToLower(), " →"),
    link.Key,
    link.Value)

Best way is to go for HtmlDecode. 最好的方法是去HtmlDecode。

@Html.ActionLink(
    String.Concat("leading ", viewModel.Text.ToLower(), HttpUtility.HtmlDecode("→")),
    link.Key,
    link.Value)

Try specifying a right arrow: 尝试指定右箭头:

@Html.ActionLink(
    String.Concat("leading ", viewModel.Text.ToLower(), " →"),
    link.Key,
    link.Value)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM