易截截图软件、单文件、免安装、纯绿色、仅160KB

Explained: Forms Authentication in ASP.NET 2.0

原地址:
http://msdn.microsoft.com/en-us/library/aa480476.aspx
IIS Authentication
ASP.NET authentication is a two-step process. First, Internet Information Services (IIS) authenticates the user and creates a Windows token to represent the user. IIS determines the authentication mode that it should use for a particular application by looking at IIS metabase settings. If IIS is configured to use anonymous authentication, a token for the IUSR_MACHINE account is generated and used to represent the anonymous user. IIS-then passes the token to ASP.NET.
Second, ASP.NET performs its own authentication. The authentication method used is specified by the mode attribute of the authentication element. The following authentication configuration specifies that ASP.NET uses the FormsAuthenticationModule class:
Copy Code
<authentication mode="Forms" />

Note   Because forms authentication does not rely on IIS authentication, you should configure anonymous access for your application in IIS if you intend to use forms authentication in your ASP.NET application.
ASP.NET Forms Authentication
ASP.NET forms authentication occurs after IIS authentication is completed. You can configure forms authentication with the forms element.
Forms Authentication Configuration
The default attribute values for forms authentication are shown in the following configuration-file fragment.
Copy Code
<system.web>
<authentication mode="Forms">
<forms loginUrl="Login.aspx"
protection="All"
timeout="30"
name=".ASPXAUTH"
path="/"
requireSSL="false"
slidingExpiration="true"
defaultUrl="default.aspx"
cookieless="UseDeviceProfile"
enableCrossAppRedirects="false" />
</authentication>
</system.web>

The default attribute values are described below:
loginUrl points to your application's custom logon page. You should place


相关文档:

ASP.NET Web Service协议相关

=================================================================================
How to enable an ASP.NET WebService to listen to HTTP POST calls
=================================================================================
Imagine you developed an ASP.NET WebService, but the client that nee ......

asp.net(c#) 制作注册码程序

1、定义CS类 using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Web.Configuration;
using Hash ......

ASP.NET 3.5 中的数据绑定

    ASP.NET 3.5中6个内置的数据源控件分别用于特定类型的数据访问。
SqlDataSource 控件   允许访问支持ADO.NET数据提供程序的所有数据源。该控件默认可以访问ODBC、OLE DB、SQL Server、Orale和SQL Server CE 提供程序
LinqDataSource  控件 可以使用LINQ 查询访问不同类型的数据对象
O ......

使用ASP.NET上传多个文件到数据库

如果仅仅是上传一个文件,最好是使用FileUpload控件,  可以使用FileUpload1.FileContent.Length得到文件大小,  FileUpload1.FileBytes得到其字节数组, 代码略.
如果要上传多个文件, 其客户端代码与使用ASP.NET上传多个文件到服务器基本相同, 本例中加入了下载的示例代码。
效果图如下:
数据库脚本
create data ......

asp.net 发送邮件

  几个月前,做用户注册模块要用到发送邮件功能,也碰到了些或大或小的问题,现在总结一下:
我先贴出发送邮件用到的代码:
public void SendEmail(string stremail, string content,string title)
{
MailMessage mm = new MailMessage();
mm.from = new MailAddress(公司邮箱) ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号