ProfileService::GetProperty (since version 2.0)
Syntax
mixed GetProperty ( string $property [, string $profileName = null ] )
Parameters
property
The property to retrieve the value from.
profileName
The profile name to use to retrieve the property value from.
Return
mixed Returns the value of the property or false if no profile is given and activated or property does not exist.
See also
Examples
<?php
ProfileService::CreateProfile('my_profile', array('name' =>'tom'));
ProfileService::UseProfile('my_profile');
$value = ProfileService::GetProperty('name');
ProfileService::ReleaseProfile();
echo($value);
?>
Ouput:
tom
ProfileService::CreateProfile('my_profile', array('name' =>'tom'));
ProfileService::UseProfile('my_profile');
$value = ProfileService::GetProperty('name');
ProfileService::ReleaseProfile();
echo($value);
?>
Ouput:
tom
<?php
ProfileService::CreateProfile('my_profile', array('name' =>'tom'));
$value = ProfileService::GetProperty('name', 'my_profile');
echo($value);
?>
Output:
tom
ProfileService::CreateProfile('my_profile', array('name' =>'tom'));
$value = ProfileService::GetProperty('name', 'my_profile');
echo($value);
?>
Output:
tom
Last change 10/13/2009