工作中css

.cs

public string BannerChange(string includeStr)
    {
        string activeStr = string.Empty;
        string ScName = Request.ServerVariables["url"].ToString();
        if (ScName.IndexOf(includeStr) > 0)
        {
            activeStr = "active";
        }
        return activeStr;
    }

.aspx

<li class="style6 <%=BannerChange("Default.aspx") %>">

posted @ 2010-11-06 11:00  zhdonghu  阅读(169)  评论(1编辑  收藏  举报