你用的什么版本的啊?我上面说的都有很详细的解释的,Indy 的官方网站有各种版本的帮助文件,我想你是没有找到。还有很好的 Demo 程序。还有一本书加《Indy In Depth》,不记得哪里有得下了,你自己搜索一下。帮助例子: --------------------------- TIdHTTP.OnAuthorization TIdHTTP Event handler for authentication of an HTTP connection. property OnAuthorization: TIdOnAuthorization; Parameters Handled Indicatesd if the authentication was successful. Sender HTTP Client generating the event notification. VPassword User authorization for the HTTP request. VUserName User identity for the HTTP request. Description OnAuthorization is a published TIdOnAuthorization property in TIdHTTP, and represents the event handler signalled when an HTTP client connection needs to provide authentication data as part of an HTTP request. VUserName and VPassword are the authentication credentials found in the HTTP Request, and can be updated in the event handler. Handled indicates if the event handler has successfully authenticated using the client account credentials and method. --------------------------------------------------------------------------------TIdHTTP.OnProxyAuthorization TIdHTTP Event handler for selecting the HTTP client authentication mechanism for a proxy connection. property OnProxyAuthorization: TIdOnAuthorization; Parameters AuthenticationClass Authentication class to use for the connection. AuthInfo Header values to use in authectication. Sender HTTP client generating the event notification. Description OnProxyAuthorization is a published TIdProxyOnAuthorization property in TIdHTTP, and represents the event handler signalled when an HTTP client selects an authentication class to be used when session or proxy authentication is required for a connection. OnProxyAuthorization is signalled prior to triggering the OnAuthorization event handler. AuthenticationClass is the class instance to be used to perform authentication for the mechanisms required in an HTTP request.AuthInfo is the header values to be be used in the HTTP response that includes the authentication results.
我用的是Delphi 6,不清楚indy是什么版本的,!《Indy In Depth》要30欧元,太贵了! 很感谢你帮我,谢谢!
编程上会用到的倒是这些事件,不过一般是高级应用才用的:
OnAuthorization
OnSelectAuthorization
OnProxyAuthorization
OnSelectProxyAuthorization
http://www.indyproject.org/ ---- Indy 的官方网站
---------------------------
TIdHTTP.OnAuthorization
TIdHTTP
Event handler for authentication of an HTTP connection.
property OnAuthorization: TIdOnAuthorization;
Parameters
Handled
Indicatesd if the authentication was successful.
Sender
HTTP Client generating the event notification.
VPassword
User authorization for the HTTP request.
VUserName
User identity for the HTTP request.
Description
OnAuthorization is a published TIdOnAuthorization property in TIdHTTP, and represents the event handler signalled when an HTTP client connection needs to provide authentication data as part of an HTTP request.
VUserName and VPassword are the authentication credentials found in the HTTP Request, and can be updated in the event handler. Handled indicates if the event handler has successfully authenticated using the client account credentials and method.
--------------------------------------------------------------------------------TIdHTTP.OnProxyAuthorization
TIdHTTP
Event handler for selecting the HTTP client authentication mechanism for a proxy connection.
property OnProxyAuthorization: TIdOnAuthorization;
Parameters
AuthenticationClass
Authentication class to use for the connection.
AuthInfo
Header values to use in authectication.
Sender
HTTP client generating the event notification.
Description
OnProxyAuthorization is a published TIdProxyOnAuthorization property in TIdHTTP, and represents the event handler signalled when an HTTP client selects an authentication class to be used when session or proxy authentication is required for a connection. OnProxyAuthorization is signalled prior to triggering the OnAuthorization event handler.
AuthenticationClass is the class instance to be used to perform authentication for the mechanisms required in an HTTP request.AuthInfo is the header values to be be used in the HTTP response that includes the authentication results.
很感谢你帮我,谢谢!