Sample Call

<?php
// SOAP_CLIENT_BASEDIR - folder that contains the PHP Toolkit and your WSDL
// $USERNAME - variable that contains your Salesforce.com username (must be in the form of an email)
// $PASSWORD - variable that contains your Salesforce.ocm password

define("SOAP_CLIENT_BASEDIR", "../../soapclient");
require_once (SOAP_CLIENT_BASEDIR.'/SforcePartnerClient.php');
require_once (SOAP_CLIENT_BASEDIR.'/SforceHeaderOptions.php');

try {
  $mySforceConnection = new SforcePartnerClient();
  $mySoapClient = $mySforceConnection->createConnection(SOAP_CLIENT_BASEDIR.'/partner.wsdl.xml');
  $mylogin = $mySforceConnection->login($USERNAME, $PASSWORD);

  echo "***** Get User Info*****\n";
  $response = $mySforceConnection->getUserInfo();
  print_r($response);
} catch (Exception $e) {
  print_r($e);
}
?>

Sample Output

***** Get User Info*****
stdClass Object
(
    [accessibilityMode] =>
    [currencySymbol] => $
    [organizationId] => 00D300000005wk2DAB
    [organizationMultiCurrency] =>
    [organizationName] => Salesforce
    [profileId] => 00e20000000lyYqBAI
    [roleId] =>
    [userDefaultCurrencyIsoCode] =>
    [userEmail] => myemail@address.com
    [userFullName] => Nick Tran
    [userId] => 00420000000tD3tABE
    [userLanguage] => en_US
    [userLocale] => en_US
    [userName] => myusername@address.com
    [userTimeZone] => America/Los_Angeles
    [userType] => Standard
    [userUiSkin] => Theme2
)