PHP Class Timber\User

Inheritance: extends Core, implements Timber\CoreInterface
Afficher le fichier Open project: jarednova/timber Class Usage Examples

Méthodes publiques

Свойство Type Description
$_link
$avatar The URL of the author's avatar
$description The description from WordPress
$display_name
$first_name The first name of the user
$id The ID from WordPress
$last_name The last name of the user
$object_type
$representation
$user_nicename

Méthodes publiques

Méthode Description
__construct ( object | integer | boolean $uid = false )
__set ( string $field, mixed $value )
__toString ( ) : string
get_custom ( ) : array | null
get_meta ( string $field_name ) : null
get_meta_field ( string $field_name ) : mixed
link ( ) : string
meta ( string $field_name ) : mixed
name ( ) : string
path ( ) : string
slug ( ) : string

Méthodes protégées

Méthode Description
init ( object | integer | boolean $uid = false )

Method Details

__construct() public méthode

public __construct ( object | integer | boolean $uid = false )
$uid object | integer | boolean

__set() public méthode

public __set ( string $field, mixed $value )
$field string
$value mixed

__toString() public méthode

public __toString ( ) : string
Résultat string a fallback for TimberUser::name()

get_custom() public méthode

public get_custom ( ) : array | null
Résultat array | null

get_meta() public méthode

public get_meta ( string $field_name ) : null
$field_name string
Résultat null

get_meta_field() public méthode

public get_meta_field ( string $field_name ) : mixed
$field_name string
Résultat mixed

init() protected méthode

protected init ( object | integer | boolean $uid = false )
$uid object | integer | boolean The user ID to use

meta() public méthode

public meta ( string $field_name ) : mixed
$field_name string
Résultat mixed

name() public méthode

public name ( ) : string
Résultat string the human-friendly name of the user (ex: "Buster Bluth")

path() public méthode

public path ( ) : string
Résultat string ex: /author/lincoln

slug() public méthode

public slug ( ) : string
Résultat string ex baberaham-lincoln

Property Details

$avatar public_oe property

The URL of the author's avatar
public $avatar

$description public_oe property

The description from WordPress
public $description

$display_name public_oe property

public $display_name

$first_name public_oe property

The first name of the user
public $first_name

$id public_oe property

The ID from WordPress
public $id

$last_name public_oe property

The last name of the user
public $last_name

$object_type public_oe property

public $object_type

$representation public_oe static_oe property

public static $representation

$user_nicename public_oe property

public $user_nicename