- dirname: documentation ( source)
<?php
$config = dirname(__FILE__) . '/hybridauth/config.php';
require_once( "hybridauth/Hybrid/Auth.php" );
try{
$hybridauth = new Hybrid_Auth( $config );
$Live = $hybridauth->authenticate( "Live" );
$user_contacts = $Live->getUserContacts();
}
catch( Exception $e ){
echo "Ooophs, we got an error: " . $e->getMessage();
}
?>