Class PlgUserProfile

Description

An example custom profile plugin.

  • since: 1.6

Located in /plugins/user/profile/profile.php (line 19)

JObject
   |
   --JEvent
      |
      --JPlugin
         |
         --PlgUserProfile
Variable Summary
Method Summary
 static void calendar ( $value)
 static void tos ( $value)
 static void url ( $value)
 PlgUserProfile __construct ( &$subject, array $config, object $subject)
 boolean onContentPrepareData (string $context, integer $data)
 boolean onContentPrepareForm (JForm $form, array $data)
 boolean onUserAfterDelete (array $user, boolean $success, string $msg)
 void onUserAfterSave ( $data,  $isNew,  $result,  $error)
 boolean onUserBeforeSave (array $user, boolean $isnew, array $data)
Variables
boolean $autoloadLanguage = true (line 35)

Load the language file on instantiation.

  • since: 3.1
  • access: protected

Redefinition of:
JPlugin::$autoloadLanguage
Affects constructor behavior. If true, language files will be loaded automatically.

Inherited Variables

Inherited from JPlugin

JPlugin::$params
JPlugin::$_name
JPlugin::$_type

Inherited from JEvent

JEvent::$_subject

Inherited from JObject

JObject::$_errors
Methods
static calendar (line 144)
  • access: public
static void calendar ( $value)
  • $value
static tos (line 156)
  • access: public
static void tos ( $value)
  • $value
static url (line 122)
  • access: public
static void url ( $value)
  • $value
Constructor __construct (line 45)

Constructor

  • since: 1.5
  • access: public
PlgUserProfile __construct ( &$subject, array $config, object $subject)
  • object $subject: The object to observe
  • array $config: An array that holds the plugin configuration
  • &$subject

Redefinition of:
JPlugin::__construct()
Constructor
onContentPrepareData (line 59)
  • since: 1.6
  • access: public
boolean onContentPrepareData (string $context, integer $data)
  • string $context: The context for the data
  • integer $data: The user id
onContentPrepareForm (line 175)
  • since: 1.6
  • access: public
boolean onContentPrepareForm (JForm $form, array $data)
  • JForm $form: The form to be altered.
  • array $data: The associated data for the form.
onUserAfterDelete (line 382)

Remove all user profile information for the given user ID

Method is called after user data is deleted from the database

  • access: public
boolean onUserAfterDelete (array $user, boolean $success, string $msg)
  • array $user: Holds the user data
  • boolean $success: True if user was succesfully stored in the database
  • string $msg: Message
onUserAfterSave (line 331)
  • access: public
void onUserAfterSave ( $data,  $isNew,  $result,  $error)
  • $data
  • $isNew
  • $result
  • $error
onUserBeforeSave (line 308)

Method is called before user data is stored in the database

  • since: 3.1
  • throws: InvalidArgumentException on invalid date.
  • access: public
boolean onUserBeforeSave (array $user, boolean $isnew, array $data)
  • array $user: Holds the old user data.
  • boolean $isnew: True if a new user is stored.
  • array $data: Holds the new user data.

Inherited Methods

Inherited From JPlugin

 JPlugin::__construct()
 JPlugin::loadLanguage()

Inherited From JEvent

 JEvent::__construct()
 JEvent::update()

Inherited From JObject

 JObject::__construct()
 JObject::def()
 JObject::get()
 JObject::getError()
 JObject::getErrors()
 JObject::getProperties()
 JObject::set()
 JObject::setError()
 JObject::setProperties()
 JObject::__toString()

Documentation generated on Tue, 19 Nov 2013 15:11:20 +0100 by phpDocumentor 1.4.3