在Asp.Net MVC中实现计算页面执行时间及简单流量统计
2009-08-24 09:53
836 查看
引用www.rsion.com.dll进您的asp.net MVC项目
本人不才,源代码中有详细说明,
查看demo
修改HomeController
public class HomeController:Controller
{
public ActionResult Index(){}
}
为
public class HomeController:www.Rsion.Com.PageExecuteTimeSpan
{
public ActionResult Index(){}
}
在View中的Home/Index中添加如下代码:
<%="提示:"+ViewData["page_execute_time"]%><Br />
从<%=String.Format("{0:D}",(DateTime)ViewData["application_start_date"]) %>起本站已经被访问
<%=ViewData["application_guest_count"] %>次!
运行结果:
提示:页面执行耗时:90毫秒
从2009年8月23日起本站已经被访问 100次! 下载源代码
希望大家支持浏览我的网站 www.CnYolee.com
本人不才,源代码中有详细说明,
查看demo
修改HomeController
public class HomeController:Controller
{
public ActionResult Index(){}
}
为
public class HomeController:www.Rsion.Com.PageExecuteTimeSpan
{
public ActionResult Index(){}
}
在View中的Home/Index中添加如下代码:
<%="提示:"+ViewData["page_execute_time"]%><Br />
从<%=String.Format("{0:D}",(DateTime)ViewData["application_start_date"]) %>起本站已经被访问
<%=ViewData["application_guest_count"] %>次!
运行结果:
提示:页面执行耗时:90毫秒
从2009年8月23日起本站已经被访问 100次! 下载源代码
希望大家支持浏览我的网站 www.CnYolee.com
相关文章推荐
- 在Asp.Net MVC中实现计算页面执行时间及简单流量统计
- asp.net2中精确计算页面执行时间原来如此简单!
- asp.net2中精确计算页面执行时间原来如此简单!
- 【MVC 过滤器的应用】ASP.NET MVC 如何统计 Action 方法的执行时间
- asp.net计算页面执行时间
- ASP.NET MVC 搭建简单网站 --1.前端页面布局和基本样式实现
- 一:理解ASP.NET的运行机制(例:通过HttpModule来计算页面执行时间)
- 一:理解ASP.NET的运行机制(例:通过HttpModule来计算页面执行时间)
- 计算出你页面执行的时间 ASP.NET
- 三行代码实现.NET MVC统计显示页面的执行时间 超简单的实现方法 分析页面执行效率
- asp.net 通过httpModule计算页面的执行时间
- asp.net计算每个页面执行时间的方法
- ASP.NET MVC页面执行时间
- ASP.NET中计算页面执行所耗时间
- C#.Net Mvc运营监控,计算方法/接口/action/页面执行时间
- 一:理解ASP.NET的运行机制(例:通过HttpModule来计算页面执行时间)
- asp.net计算每个页面执行时间的方法
- ASP.NET MVC 学习4、Controller中添加SearchIndex页面,实现简单的查询功能
- MVC 实现计算页面执行时间