E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
HttpContext
获取指定文件路径
string path=
HttpContext
.Current.Server.MapPath("FileName") FileName可以是文件名称,也可以是文件夹名称!
yuyangsoft
·
2010-03-02 17:00
C++
c
Web
C#
HttpContext
.Current.Cache 和 HttpRuntime.Cache 区别
HttpContext
.Current.Cache 只可能用于 Web 应用的缓存 适应的地方: public static void UserHashByMap(int uId) {  
·
2010-03-02 15:00
Runtime
Cache在aspx.cs和xxx.CS里的不同用法
在普通aspx.cs代码里可以用: Cache cache = new Cache(); 但在XXXX.CS里,就不能用上面的方式了,得用: 永不时间过期
HttpContext
.Current.Cache.Insert
·
2010-02-26 15:00
cache
asp.net vs2008 vs2008 不实现接口成员System.Web.IHttpHandler.IsReusable
ASP.default_aspx.GetTypeHashCode()”: 没有找到适合的方法来重写 错误 2 “ASP.default_aspx.ProcessRequest(System.Web.
HttpContext
heisetoufa
·
2010-02-25 20:00
c
Web
.net
asp.net
asp
asp.net vs2008 vs2008 不实现接口成员System.Web.IHttpHandler.IsReusable
ASP.default_aspx.GetTypeHashCode()”: 没有找到适合的方法来重写 错误 2 “ASP.default_aspx.ProcessRequest(System.Web.
HttpContext
heisetoufa
·
2010-02-25 20:00
c
Web
.net
asp.net
asp
asp.net vs2008 vs2008 不实现接口成员System.Web.IHttpHandler.IsReusable
ASP.default_aspx.GetTypeHashCode()”: 没有找到适合的方法来重写 错误 2 “ASP.default_aspx.ProcessRequest(System.Web.
HttpContext
heisetoufa
·
2010-02-25 20:00
c
Web
.net
asp.net
asp
asp.net vs2008 vs2008 不实现接口成员System.Web.IHttpHandler.IsReusable
ASP.default_aspx.GetTypeHashCode()”: 没有找到适合的方法来重写 错误 2 “ASP.default_aspx.ProcessRequest(System.Web.
HttpContext
heisetoufa
·
2010-02-25 20:00
c
Web
.net
asp.net
asp
asp.net vs2008 vs2008 不实现接口成员System.Web.IHttpHandler.IsReusable
ASP.default_aspx.GetTypeHashCode()”: 没有找到适合的方法来重写 错误 2 “ASP.default_aspx.ProcessRequest(System.Web.
HttpContext
heisetoufa
·
2010-02-25 20:00
c
Web
.net
asp.net
asp
URL重写有几种方式:
1).通过
HttpContext
类的RewriteUrl()方法来执行URL重写;2).通过自定义HTTPModule或HTTPHandler来重写URL;3).借助正则表达式来重写URL:理解重写的方式
zxl315
·
2010-02-24 13:00
Microsoft
url
asp.net
Path
documentation
引擎
把UserControl通过代码控制输入HTML
用
HttpContext
获得Server对象,然后执行Execute方法,看代码: public string RenderView(UserControl control){ Page page=
format
·
2010-02-22 10:00
创建自定义路由约束(C#)
这个接口极其简单,就描述了一个简单方法: bool Match(
HttpContext
javahigh1
·
2010-02-07 12:00
C++
c
mvc
Web
C#
获取客户端的ip地址
//获取客户端的ip地址 public string GetClientIP() { string result =
HttpContext
.Current.Request.ServerVariables
deepwishly
·
2010-01-25 21:00
String
null
Silverlight:如何在程序中获取网站的根目录
如果需要在Silverlight程序中获取当前网站的根目录,不能使用
HttpContext
.Current这样的方式,而需要用@HostingEnvironment.ApplicationPhysicalPath
chen_xizhang
·
2010-01-21 07:00
IHttpHandler的妙用(2):防盗链!我的资源只有我的用户才能下载
大家查看一个msdn,可以看到它的声明如下:Visual Basic(声明) Sub ProcessRequest ( _ context As
HttpContext
_) Visual Basic
dz45693
·
2010-01-18 21:00
数据库
session
server
Authentication
asp.net
redirect
ASP.NET中在自定义类中使用Session,Request,Response,Server
方法1:usingSystem.Web;
HttpContext
.Current.Session["a"]="hello";另:需要你先定义publicSystem.Web.SessionState.HttpSessionStateSession
w809026418
·
2010-01-06 11:00
server
session
null
asp.net
导出excel乱码
C#ASP.NET导出Excel乱码最终解决方案此方法直接调用即可页面直接调用Export(gdvDataList,"DataLog.xls",
HttpContext
.Current);页面直接调用Export
kexijun20014
·
2009-12-26 17:00
.net 操作XML小结
using System.Xml;//初始化一个xml实例XmlDocument xml=new XmlDocument(); //导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
Felix韩
·
2009-12-16 18:00
C++
c
xml
.net
C#
深入解析HTTP运行时
HTTP运行期首先创建一个
HttpContext
对象的实例,它包含了当前正在处理的请求信息,接着创建在处理
·
2009-12-15 00:00
http
Cookies+Session保存用户登陆状态
Session方式,虽然设置了超时时间,但是好像登陆状态经常会动不动就丢失,导致客户抱怨不断,今天仔细的考虑了一下,决定采用Cookies跟Session结合的方式来判断用户的登陆状态代码如下:1、用户登陆代码
HttpContext
.Current.Session.Abandon
sunboy_2050
·
2009-12-07 16:00
session
String
服务器
Cookies
null
Cookies+Session保存用户登陆状态
虽然设置了超时时间,但是好像登陆状态经常会动不动就丢失,导致客户抱怨不断,今天仔细的考虑了一下,决定采用Cookies跟Session结合的方式来判断用户的登陆状态 代码如下: 1、用户登陆代码
HttpContext
.Current.Session.Abandon
king_tt
·
2009-12-07 16:00
session
asp.net站点URLRewrite小记
其实就是在BeginRequest事件中调用
HttpContext
的RewritePath方法,将该请求重新“
ulark
·
2009-12-01 17:00
object
application
url
Class
asp.net
IIS
asp.net文件下载[转]
System.Web.UI.Page 2 { 3 //提供下载的文件,不编码的话文件名会乱码 4 private string fileName =
HttpContext
.Current.Server.UrlEncode
ulark
·
2009-12-01 17:00
Stream
测试
null
asp.net
buffer
byte
asp.net 站点URLRewrite使用小记
其实就是在BeginRequest事件中调用
HttpContext
的RewritePath方法,将该请求重新“定位”至一个目标URL就完成了。在站点的Global.asax文件BeginRe
·
2009-11-30 20:01
真正的获取客户端真实IP地址及利弊分析
多数代码类似:复制代码代码如下:stringIpAddress=(
HttpContext
.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR"]!
·
2009-11-30 19:29
asp.net 获取IP的相关资料
ASP.net获得客户端的IP,最常见的是使用下述代码:复制代码代码如下:stringuser_IP=System.Web.
HttpContext
.Current.Request.ServerVariables
·
2009-11-30 19:16
ajax实现异步获取数据 (js创建ajax对象)
IsPostBack){stringtest=
HttpContext
.Current.Request.QueryString["userName"];stringok=(string)SqlHelper.ExecuteScalar
vip__888
·
2009-11-25 19:00
c#获取真实IP和代理IP
获取真实IPpublic static string GetRealIP() { string ip; try { HttpRequest request =
HttpContext
.Current.Request
ihuashao
·
2009-11-25 15:00
html
C++
c
C#
HttpContext
的简单应用
HttpContext
.Current.Request["username"];//取提交信息
HttpContext
.Current.Response.Write("");//向客户端写信息
HttpContext
.Current.Session
qiume
·
2009-11-20 13:00
.NET开发中你可能会用到的常用方法总结
///////////publicstaticstringGetTempleContent(stringpath){stringresult=string.Empty;stringsFileName=
HttpContext
.Current.Server.MapPa
xd43100678
·
2009-11-19 21:00
.net
String
服务器
null
byte
extension
执行.sql安装文件代码
stringpath1=
HttpContext
.Current.Server.MapPath("~/install/1.sql");stringpath2=
HttpContext
.Current.Server.MapPath
gdjlc
·
2009-11-18 22:00
String
Path
asp.net url重写后页面回传问题
HtmlTextWriter方法,重写属性输出WriteAttribute(stringname,stringvalue,boolencode)方法,当输出action时,将action属性的值强制转换为当前虚URL(
HttpContext
.Current.Request.RawUrl
·
2009-11-11 00:50
URL重写小结
一,自己手动在asp.net级别的重写, 通过System.Web.
HttpContext
类的RewritePath()方法,可以在ASP.NET级别实现URL重写。
diandian82
·
2009-11-05 21:00
windows
String
Microsoft
application
url
asp.net
Json.net与Jquery简单示例
using Newtonsoft.Json;(导入空间) 官方网站:http://www.codeplex.com/Json public void ProcessRequest (
HttpContext
·
2009-11-04 11:00
jquery
HttpRuntime.cache
一,两个实现代码的差异:我们用.NETReflector 看
HttpContext
类的Cache属性,会看到如下代码: public CacheCache ...
lidup
·
2009-10-30 16:34
职场
休闲
HttpRuntime.cache
一,两个实现代码的差异:我们用.NETReflector看
HttpContext
类的Cache属性,会看到如下代码:publicCacheCache...{get...
lidup
·
2009-10-30 16:34
职场
休闲
Asp.Net
HttpRuntime.cache
一,两个实现代码的差异:我们用.NETReflector 看
HttpContext
类的Cache属性,会看到如下代码: public CacheCache ...
lidup
·
2009-10-30 16:34
职场
休闲
asp.net获取真实ip
publicstringgetip() { stringresult=
HttpContext
.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR
jiedushi
·
2009-10-16 15:00
C#操作XML小结
using System.Xml;//初始化一个xml实例XmlDocument xml=new XmlDocument(); //导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
wapysun
·
2009-10-01 20:00
xml
C#操作XML小结
、简单介绍usingSystem.Xml;//初始化一个xml实例XmlDocumentxml=newXmlDocument();//导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
vrix
·
2009-10-01 20:00
C#操作XML小结
、简单介绍usingSystem.Xml;//初始化一个xml实例XmlDocumentxml=newXmlDocument();//导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
sahusoft
·
2009-09-26 09:00
xml
String
C#
user
null
encoding
分用户文件夹上传图片
Directory.Exists(
HttpContext
.Current.Server.MapPath("uploadfile/")+"//"+CurrentLoginUser.LoginName+"/
lsgy2008
·
2009-09-22 15:00
String
产品
浅谈ASP.NET管道优化
例如,SessionStateModule拦截每个请求,并解析对应的会话cookie,然后在
HttpContext
中加载适当的会话。实时证明,并不是所有的modules都是必要的。
jhlovett
·
2009-09-20 21:00
.net
Web
asp.net
mobile
asp
asp.net中判断链接来源
在asp.net中判断链接来源的代码如下: public bool IsUrl() { string str1 = System.Web.
HttpContext
.Current.Request.ServerVa
lovexuwenhao
·
2009-09-16 22:00
html
Web
.net
asp.net
asp
WebFormView的标准修改办法及MvcPatch项目
上一篇文章中我提到WebFormView的实现破坏了IView对象设计思路,它会把视图内容直接生成至
HttpContext
.Current而不是Render方法指定的TextWriter中。
老赵点滴 - 追求编程之美
·
2009-09-15 12:00
ASP.ENT C# 文件下载函数
publicstaticboolDownFile(stringfilePath){try{if(File.Exists(filePath)){
HttpContext
.Current.Response.Clear
zhoukang0916
·
2009-09-11 22:00
HttpContext
.Current.Items用途
HttpContext
.Current.Items只在一次Http请求中存活,适用于:Server.Transfer();HTTP请求过程中在IHttpModule和IHttpHandler之间组织和共享数据
tangzhongxin
·
2009-09-07 17:00
C#怎么改变图像的大小,比例
使用缩略图的方法就可以实现图片的大小变换,具体的方法如下:System.Drawing.Imageimage=System.Drawing.Image.FromFile(
HttpContext
.Current.Server.MapPath
hanghwp
·
2009-09-04 00:00
image
String
C#
asp.net 类库中使用Session
添加System.Web引用,然后导入以下两个命名空间usingSystem.Web;usingSystem.Web.Security;然后取值:objecto=
HttpContext
.Current.Session
jzdzhiyun
·
2009-09-03 12:00
导出到excel,如果不保存,会自动关闭页面的问题
//不显示删除回复显示所有回复显示星级回复显示得分回复DataGrid导出到excel,如果不保存,会自动关闭页面的问题 //
HttpContext
.Current.Response.AppendHeader
xushichang
·
2009-09-03 12:00
ASP.NET 根路径的获取
/// 虚拟应用程序根路径 /// </summary> public string ApplicationPath { get { _ApplicationPath =
HttpContext
.Current.Request
jianwei.lau
·
2009-08-26 00:00
C++
c
.net
asp.net
asp
上一页
34
35
36
37
38
39
40
41
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他