62,046
社区成员
发帖
与我相关
我的任务
分享
public static string GetContentKeywordsReplacement(string input)
{
string reval = input;
List<CZ_Keyword> keywords = CZ.Bussiness.CZCacheProxy.GetKeywords();
foreach (CZ_Keyword keyword in keywords)
{
if (string.IsNullOrEmpty(keyword.KeywordUrl))
{
reval = reval.Replace(keyword.KeywordName, string.Format("<strong>{0}</strong>", keyword.KeywordName));
}
else
{
reval = reval.Replace(keyword.KeywordName, string.Format("<a href=\"{1}\" target=\"_blank\"><strong>{0}</strong></a>", keyword.KeywordName, keyword.KeywordUrl));
string ff = string.Format("<a href=\"{1}\" target=\"_blank\"><strong>{0}</strong></a>", keyword.KeywordName, keyword.KeywordUrl);
}
}
return reval;
}