ASP.NET中Server与Request对象的方法
Server 對象的方法:
UrlEncode(ByVal String As String)As String 將URL字符串編碼
UrlDecode(ByVal String As String)As String 將編碼后的URL字符串解碼
MapPath(ByVal path As String)As String MaDPath 取得文件的實際路徑
HtmlEncode(ByVal String As String)As StringHtmlEncode 將字符串編碼為HTML數據
HtmlDecode(ByVal String As String)As String HtmlDecode 將HTML編碼后的數據解碼還原為HTML
Request 對象的屬性
UserLanguages 客戶端主機所使用的語言
UserHostName 客戶端主機的DNS名稱
userHostArrress 客戶端主機的IP地址
UserAgent 客戶端瀏覽器版本
Url 當前要求的URL
TotalBytes 當前輸入的容量大小
ServerVariables 網頁的Server變量
RequestType 客戶端網頁的傳送方式(Get/Post)
RawUrl 當前頁面的U『RL
QueryString 瀏覽器地址欄后的參數
PhysicalPath 當前網頁在服務器端的實際路徑
PhysicalApplicationPath 當前在服務器端執行的程序的實際路徑
Pathq 當前網頁的相對地址
Params 返回QueryString、Form、Cookies、ServerVariables的全部集合
IsSecureConnection 目前聯機的安全性
IsAuthenticated 目前聯機是否有效
HttpMethod 目前客戶端網頁的傳送方式(Get/Post)
Headers 網頁的標題集合
Form 窗體變量
Files 客戶端上傳的文件
FilePath 當前執行網頁的相對地址
Cookies HttpCookieCollection對象集合
ContentType 當前需求的MIME內容類型
ContentEncoding 客戶端瀏覽器的字符設置 -
ConnectionlD 客戶端所提出的網頁瀏覽請求的聯機的ID
ClientCertificate 客戶端安全認證信息
Browser 客戶端瀏覽器的信息
AnnlicationPath 當前運行程序的服務器端虛擬目錄
轉載于:https://www.cnblogs.com/leeolevis/archive/2009/02/03/1383114.html
總結
以上是生活随笔為你收集整理的ASP.NET中Server与Request对象的方法的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 整合SharePoint MOSS 和S
- 下一篇: 【转】Scott_ASP.NET MVC