Search by

wentthefox / services_libravatar

WentTheFox

API interfacing class for libravatar.org

Package info

github.com/WentTheFox/Services_Libravatar

Homepage

Issues

pkg:composer/wentthefox/services_libravatar

Statistics

Installs: 23

Dependents: 0

Suggesters: 0

Stars: 0

v1.0.5 2026-10-05 05:26 UTC

This package is auto-updated.

Last update: 2026-10-05 05:26:48 UTC


README

A PHP 8.4+ library to the Libravatar service that delivers avatar pictures to other websites: It gives you image URLs for email addresses.

Forked from https://github.com/pear/Services_Libravatar

Installation

Via Composer:

$ composer require wentthefox/services_libravatar

Usage

<?php

require 'vendor/autoload.php';

use PEAR\Services\Libravatar;

$emailOrHash = 'test@example.com';
# OR $emailOrHash = '55502f40dc8b7c769880b10874abc9d0';

$service = new Libravatar();
$service->setHttps(true);
$service->setSize(128);
echo $service->getUrl($emailOrHash);
# https://seccdn.libravatar.org/avatar/55502f40dc8b7c769880b10874abc9d0?size=128

Additional documentation available at the original source. Most methods signatures are identical.