addBasicAuthenticationHeaderWithUsername:andPassword: method

Constructs a basic authentication header from the user name and password supplied, and adds it to the request headers.

Syntax

- ( void ) addBasicAuthenticationHeaderWithUsername : ( NSString * ) theUsername andPassword : ( NSString * ) thePassword

Usage

It is used when shouldPresentCredentialsBeforeChallenge is set to YES.