Connect

From PHRETS


Syntax

Connect ( string $login_url, string $username, string $password [, string $ua_pwd ] )

Makes initial RETS Login connection. If RETS 'Action' exists, performs that request as well.


Parameters

$login_url
Full Login URL to the RETS server
$username
Login username
$password
Login password
$ua_pwd
Optional. User-Agent Password.

Default is blank. If not blank, User-Agent Authentication is forced.


Return Values

Boolean
If any part of the initial connection failed, returns FALSE (check Error for details). Otherwise, returns TRUE


Changelog

Version Description
1.0 Dropped AddHeader requirements


Examples

Connects
$connect = $rets->Connect("http://demo.crt.realtors.org:6103/rets/login", "Joe", "Schmoe");
if (!$connect) {
        print_r($rets->Error());
}
Connects with User-Agent Authentication
$connect = $rets->Connect("http://demo.crt.realtors.org:6103/rets/login", "Joe", "Schmoe", "ua-password");


Related to

Views
Personal tools