2017 © Pedro Peláez
 

yii2-extension yii2-gravatar-widget

Gravatar widget for Yii2

image

alexeevdv/yii2-gravatar-widget

Gravatar widget for Yii2

  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 1 % Grown

The README.md

yii2-gravatar-widget

Build Status codecov PHP 5.6 PHP 7.0 PHP 7.1 PHP 7.2 PHP 7.2, (*1)

Yii2 wrapper for Gravatar service., (*2)

Installation

The preferred way to install this extension is through composer., (*3)

Either run, (*4)

$ php composer.phar require alexeevdv/yii2-gravatar-widget

or add, (*5)

"alexeevdv/yii2-gravatar-widget": "^1.0"

to the require section of your composer.json file., (*6)

Usage

echo \alexeevdv\yii\gravatar\Widget([
    "email" => "mail@example.com", // required
]);

Params

/**
 * User email address
 */
string $email;

/**
 * Use HTTPS connection?
 */
bool $secure = true;

/**
 * Append .jpg extension?
 */
bool $extension = true;

/**
 * Avatar width and height. Must be beetween 1 and 2048
 */
integer $size;

/**
 * Default image if avatar is not available. Must be valid image URI or one of the following strings:
 * "404", "mm", "identicon", "monsterid", "wavatar", "retro", "blank"
 */
string $defaultImage;

/**
 * Force default image even if the avatar is available?
 */
bool $forceDefault = false;

/**
 * Allowed avatar rating. Must be one of the following strings:
 * "g", "pg", "r", "x"
 */
string $rating;

/**
 * Additional HTML attributes to img tag
 */
array $options = [];

For more information see Gravatar manual., (*7)

The Versions

22/09 2015

dev-master

9999999-dev

Gravatar widget for Yii2

  Sources   Download

MIT

The Requires

 

yii2 widget avatar gravatar