0
我正在運行asp.net MVC剃鬚刀。我試圖從我的視圖中的字符串中刪除引號。如何刪除asp.net MVC視圖中的特殊字符
所以我回到這個
"<p><strong>test</strong</p>"
and my wanting this
<p><strong>test</strong></p>
這裏是我已經試過:
@foreach (var post in Model)
{
var cont = post.postContent.Trim('"');
<div class="post">
<h2>@Html.ActionLink(post.postTitle, "Details", "Home", new { id = post.postId }, null)</h2>
@cont
<p>@post.postDate</p>
</div>
}
'String.Replace()'? – SouthShoreAK 2012-04-19 19:06:39