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
Chrome内核下由ashx输出的js代码不起作用的解决方法
stringmessage){ResponseScript("alert('"+message+"');");}publicstaticvoidResponseScript(stringscript){
HttpContext
.Current.Response.Write
·
2013-03-29 09:47
MVC3小技巧
2.Request.QueryString["date1"]
HttpContext
.Current.Request.QueryString["data1"]3.UpdateModel(v)4.Model
Raywang80s
·
2013-03-29 09:00
获取网站根目录地址(绝对路径地址)
//////获取路径//////publicstringGetRootURI(){stringAppPath="";HttpContextHttpCurrent=
HttpContext
.Current;
bestreally
·
2013-03-24 08:29
sharepoint 2010 获取用户信息UserProfile方法
Microsoft.Office.Server.dll,Microsoft.Office.Server.UserProfiles.dll2.获取用户登录名,例如cxx\mossadminstringLoginName=System.Web.
HttpContext
.Current.User.Identity.Name.ToString
cxx2325938
·
2013-03-20 03:00
SharePoint
获取用户名
UserProfile
读取用户配置文件
asp.net获取URL和IP地址的方法汇总
HttpContext
.Current.Request.Url.ToString()并不可靠。如果当前URL为http://localhost/search.aspx?
·
2013-03-19 09:20
gridveiw导出Excel
//TODO:在此处添加构造函数逻辑 // } publicstaticvoidToExcel(stringfileName,GridViewgv) {
HttpContext
.Current.Response.Clear
miaoshaohoa
·
2013-03-14 17:00
细说 HttpHandler 的映射过程
阅读目录开始回顾HttpHandlerHttpHandler的映射过程
HttpContext
.RemapHandler()
HttpContext
.RemapHandler()的另类用途GetHandlerMapping
·
2013-03-07 09:00
handler
Session校验的两种方式
netframework来处理 浏览器——文件——iis->aspnetisapi.dll->.netframework->
HttpContext
对象封装了请求报文——>HttpApplication
hacjj
·
2013-03-01 20:43
session
SharePoint中获取当前登录的用户名
第一种方法: System.Web.
HttpContext
.Current.User.Identity.Name.ToString(); 或者: SPContext.Current.Site.OpenWeb
·
2013-02-26 11:00
SharePoint
C#导出csv文件 防止中文乱码的解决方案
stringexportFileName="Export"+DateTime.Now.ToString("yyyyMMddHHmmss"); System.Web.HttpContextcontext=System.Web.
HttpContext
.Current
dannywj1371
·
2013-02-22 17:00
.Net MVC中Html.RenderPartial和Html.RenderAction 的应用与区别
阅读更多Html.Partial方法:是将视图内容直接生成一个字符串并返回,Html.RenderPartial方法是直接输出至当前
HttpContext
,而Html.RenderAction还调用一下
guangqiang
·
2013-02-19 16:00
asp.net
.net
mvc
web
C#
.Net MVC中Html.RenderPartial和Html.RenderAction 的应用与区别
Html.Partial方法:是将视图内容直接生成一个字符串并返回,Html.RenderPartial方法是直接输出至当前
HttpContext
,而Html.RenderAction还调用一下Action
guangqiang
·
2013-02-19 16:00
Web
.net
mvc
C#
asp.net
asp.net Cookie值中文乱码问题解决方法
我们以asp.net为例,代码如下:设置Cookie时:复制代码代码如下:HttpCookiecookie=newHttpCookie("name",System.Web.
HttpContext
.Current.Server.UrlEncode
·
2013-02-17 11:51
asp.net静态方法弹出对话框实现思路
///弹出JavaScript小窗口,其实就是定义的一个DIV//////窗口信息publicstaticvoidAlert(stringmessage){message=""+message+"";
HttpContext
.Current.Response.Writ
·
2013-02-07 10:41
asp.net mvc3:自己编写的一些垃圾代码,删前分享(2013-01-18)
returnvc.RequestContext.
HttpContext
.Request.Params["view"]!=null ?vc.RequestContext.
HttpContext
cheny_com
·
2013-01-18 09:00
aspx解析之后的html代码获取
/////////publicstringGetHtmlData(stringvirtualPath){StringWriterwriter=newStringWriter();stringpath=
HttpContext
.Current.Request.Url.Scheme
xiaojingxaut
·
2013-01-15 09:47
html
aspx
C#
aspx解析之后的html代码获取
publicstringGetHtmlData(stringvirtualPath) { StringWriterwriter=newStringWriter(); stringpath=
HttpContext
.Current.Request.Url.Sch
xiaojingxaut
·
2013-01-15 09:47
html
aspx
asp.net查询本地IP
publicstaticstringGetIP(){stringresult=String.Empty;result=
HttpContext
.Current.Request.ServerVariables
ethan永不言弃
·
2013-01-12 16:22
[Asp.net] Windows驗證的網站(包含IIS取消匿名驗證改Windows驗證)
Web.config中將程式碼中利用下列代碼抓出使用者名稱1
HttpContext
.Current.User.Identity.Name.Substring(
HttpContext
.Current.User.Identity.Name.IndexOf
·
2013-01-10 11:00
windows
.NET连接数据库字符串
System.Configuration.ConfigurationManager.ConnectionStrings["myorderConnectionString"].ToString();2、web.config设置: 代码访问:publicstaticstringdbpath=
HttpContext
.C
wangqiuyun
·
2013-01-07 00:00
Asp.net中提示【当前上下文中不存在名称“Request“或"Server"】解决方法!
HttpFileCollection files = System.Web.
HttpContext
.Current.Request.Files; string url = System.Web.
HttpContext
.Current.Server.MapPath
xitong
·
2012-12-29 18:00
asp.net
Asp.net中提示【当前上下文中不存在名称“Request“或"Server"】解决方法!
HttpFileCollectionfiles=System.Web.
HttpContext
.Current.Request.Files; stringurl=System.Web.
HttpContext
.Current.Server.MapPath
dxnn520
·
2012-12-29 18:00
Authorize attribute and jquery AJAX in asp.net MVC
protectedoverridevoidHandleUnauthorizedRequest(AuthorizationContextfilterContext) { if(filterContext.
HttpContext
.Requ
pipi0714
·
2012-12-13 19:00
Asp.net删除Cookie
///Cookie的名称 ///Cookie的domain ///布尔类型 publicstaticvoidDeleteCookie(stringCoName,stringdomain) { if(
HttpContext
.Current.Request.Browser.Cookies
kaosini
·
2012-11-29 10:00
asp.net mvc源码分析-Route的GetRouteData
首先我们还是来看看GetRouteData方法吧publicoverrideRouteDataGetRouteData(HttpContextBasehttpContext){stringvirtualPath=
httpContext
.Request.AppRelativeCur
dz45693
·
2012-11-21 13:37
ASP.NET
MVc
HttpResponse的Output与OutputStream、Filter关系与区别介绍
在网上经常看见有这样的代码HttpResponseresponse=
HttpContext
.Current.Response;response.Filter=newPageFilter(response.Filter
·
2012-11-07 15:27
HttpResponse的Output与OutputStream、Filter关系与区别
在网上经常看见有这样的代码 HttpResponseresponse=
HttpContext
.Current.Response; response.Filter=newPageFilter
·
2012-11-06 20:00
OutputStream
asp.net Excel导出及数据格式化处理(摘)
public void ToExcel(System.Web.UI.Control ctl, string FileName) {
HttpContext
.Current.Response.Charset
GoodShot
·
2012-10-25 09:00
C#操作XML方法详解
usingSystem.Xml;//初始化一个xml实例XmlDocumentxml=newXmlDocument();//导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
烈日轨迹
·
2012-10-23 10:00
HttpContext
类
在处理请求执行链的各个阶段中,会有一个对象在各个对象之间进行传递,也即会保存请求的上下文信息,这个对象就是
HttpContext
对象。
i_lovefish
·
2012-10-11 16:00
object
server
String
url
asp.net
textbox
C#操作XML小结
、简单介绍usingSystem.Xml;//初始化一个xml实例XmlDocumentxml=newXmlDocument();//导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
accountwcx
·
2012-10-09 08:00
xml
C#
WEB服务 单点登出 不了的问题
null) Session.Abandon(); FormsAuthentication.SignOut();
HttpContext
.Current.Response.Cookies.Clear
longlong821
·
2012-10-08 13:00
C#操作XML方法详解
using System.Xml;//初始化一个xml实例XmlDocument xml=new XmlDocument(); //导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
·
2012-09-25 20:00
xml
C#获取IP等网络信息
Page.Request.UserHostName;//获取客户端主机名称 Page.Request.UserHostAddress;//获取客户端主机IP地址2WebService中获取客户端IP信息
HttpContext
.Current.Request.UserHostAddress
accountwcx
·
2012-09-25 17:00
编程
网络
C#
asp.net
C#操作XML
using System.Xml;//初始化一个xml实例XmlDocument xml=new XmlDocument(); //导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
·
2012-09-23 22:00
xml
在一般处理文件中访问Session需要添加IRequiresSessionState
System.Web.
HttpContext
.Current
v5qqbrowser
·
2012-09-19 10:00
session
.net XML文档操作
usingSystem.Xml; //初始化一个xml实例 XmlDocumentxml=newXmlDocument(); //导入指定xml文件 xml.Load(path); xml.Load(
HttpContext
.Curre
angle860123
·
2012-09-17 15:00
xml
.net
String
null
文档
encoding
.NET面向上下文、AOP架构模式(概述)
在ASP.NET框架中比较经典的就是
HttpContext
上下文
海水正蓝
·
2012-09-12 22:00
C#读取设置Cookie
设置:HttpCookiecookie=newHttpCookie("cookieName"); cookie.Value="name1"
HttpContext
.Current.Response.Cookies.Add
·
2012-09-10 17:00
cookie
页面中的内容输出到word,并下载
newHtmlTextWriter(tw);this.pan_content.RenderControl(hw);System.Web.HttpResponseresponse=System.Web.
HttpContext
.Current.Respon
·
2012-09-10 10:00
word
一般处理程序中
httpContext
.current.session为null的解决办法
在该一般处理程序中添加引用:using System.Web.SessionState; 给该类添加接口:publicclassAddArticle:IHttpHandler,IRequiresSessionState
·
2012-09-05 10:00
session
生成和读取XML文件的方法
/ ///需要传的参数 publicstaticvoidgetXml(DataTabledt) { stringpath=System.Web.
HttpContext
.Current.Server.MapPath
苍穹断雪
·
2012-09-04 17:46
XML文件
读取xml文件
生成xml文件
c#类文件下使用Server.MapPath()方法
1、首先引用usingSystem.Web该命名空间,然后直接使用
HttpContext
.Current.Server.MapPath()2、直接写System.Web.
HttpContext
.Current.Server.MapPath
苍穹断雪
·
2012-09-04 17:46
C#
.net操作xml小结
、简单介绍usingSystem.Xml;//初始化一个xml实例XmlDocumentxml=newXmlDocument();//导入指定xml文件xml.Load(path);xml.Load(
HttpContext
.Current.Server.MapPath
hjh2005
·
2012-08-31 09:00
从远程服务器下载文件到本地服务器
publicvoidDownloadFile(stringsourceUri,stringfilePath){stringpath=
HttpContext
.Current.Server.MapPath(
keyrainie
·
2012-08-29 17:53
HttpContext
.Current.Cache vs. HttpRuntime.Cache
原文地址:http://www.cnblogs.com/freshman0216/archive/2008/07/15/1243685.html.NET中Cache有两种调用方式:
HttpContext
.Current.Cache
ArvinStudy
·
2012-08-29 09:00
cache
object
String
null
Class
asp.net
System.Web.
HttpContext
.Current.Cache和System.Web.HttpRuntime.Cache有什么区别?
来自:http://www.cnblogs.com/qiantuwuliang/archive/2009/12/28/1634571.html System.Web.
HttpContext
.Current.Cache
ArvinStudy
·
2012-08-29 09:00
asp.net获取网站路径
网站在服务器磁盘上的物理路径:HttpRuntime.AppDomainAppPath虚拟程序路径:HttpRuntime.AppDomainAppVirtualPath任何于Request/
HttpContext
.Current
xingxing513234072
·
2012-08-28 01:00
.net xml操作使用方法说明
//导入指定xml文件5.xml.Load(path);6.xml.Load(
HttpContext
.Current.Server.MapPath("~/file/bookstore.xml"));7.
wyxhd2008
·
2012-08-25 11:00
.net
xml
Path
C#连接各种数据库语句(实例)
usingSystem.Data; usingSystem.Data.OleDb; connString="Provider=Microsoft.Jet.OleDb.4.0;DataSource="+System.Web.
HttpContext
.Current.Server.MapPath
smartsmile2012
·
2012-08-23 16:00
数据库
properties
server
C#
Security
database
上一页
28
29
30
31
32
33
34
35
下一页
按字母分类:
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
其他