string html="<font color='red'>"+DateTime.Now.ToString("yyyy-MM-dd")+"</font>";
在页面上
@html
输出的是<font color='red'>2011-12-28</font>
请问怎样才能将<font>标签解析?
显示红色的日期

解决方案 »

  1.   

    Response.Write(html)  输入会出问题??很可能是你在页面输出的时候写错了吧..
      

  2.   

    ASP.NET ,,我前台放 lable 和button ,, 当点击BUTTON时。。 string html = "<font color='red'>" + DateTime.Now.ToString("yyyy-MM-dd") + "</font>";
                Label1.Text = html;2011-12-30 显示的是红色。。   。。 没有问题呀?