摘要:
MVC分页源码全面兼容Bootstrapusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Web;namespace System.Web.Mvc{ public static class TKHtml { public static HtmlString Pager(this HtmlHelper htmlHelper, string url, int currentPage, int pageSize, int totalCo... 阅读全文
摘要:
动态配置WebC.Config采用Linq string xmlPath = Server.MapPath("/web.config"); XElement rootNode = XElement.Load(xmlPath); var custs = (from c in rootNode.Elements("appSettings").Elements("add") select c).ToList(); foreach (XElement node in ... 阅读全文
摘要:
在系统中会看到 Question/123 由来改写路由 public override void RegisterArea(AreaRegistrationContext context) { context.MapRoute( "Question_default", "Question/{id}", new { controller = "Home", action = "Index", id = UrlParameter.Optional } ... 阅读全文