Gravatar
    
            
            in package
            
        
    
    
    
Gravatar class.
Tags
Table of Contents
Properties
- $gravatarUrlBase : string
 
Methods
- getImage() : string
 - Get Gravatar image tag with URL or just URL.
 
Properties
$gravatarUrlBase
    public
        string
    $gravatarUrlBase
     = 'https://www.gravatar.com/avatar/'
    
        Gravatar URL base with trailing slash.
Methods
getImage()
Get Gravatar image tag with URL or just URL.
    public
                    getImage(string $email[, int $size = 80 ][, string $default = 'mp' ][, string $rating = 'g' ][, bool $htmlImg = false ][, array<string|int, mixed> $htmlImgAttributes = [] ]) : string
    Parameters
- $email : string
 - 
                    
The email address of target Gravatar.
 - $size : int = 80
 - 
                    
Gravatar size.
 - $default : string = 'mp'
 - 
                    
Default image. Accept: 404, mp, identicon, monsterid, wavatar, retro, robohash, blank.
 - $rating : string = 'g'
 - 
                    
Rating. Accept: g, pg, r, x.
 - $htmlImg : bool = false
 - 
                    
Set to
trueto return<img>tag. Default isfalsemeans it will be return only URL. - $htmlImgAttributes : array<string|int, mixed> = []
 - 
                    
The associative array of
imgattributes. 
Tags
Return values
string —Return URL or img tag with URL.