Skip to main content
Back to packages
547 GitHub stars

creativeorange/gravatar

View on GitHub

Description

A Laravel Gravatar package for retrieving gravatar image URLs or checking the existance of an image

Within your controllers or views, you can use

Gravatar::get('[email protected]');

This will return the URL to the gravatar image of the specified email address. In case of a non-existing gravatar, it will return return a URL to a placeholder image. You can set the type of the placeholder in the configuration option fallback.

Alternatively, you can check for the existence of a gravatar image by using

Gravatar::exists('[email protected]');

This will return a boolean (true or false).

Or you can pass a url to a custom image using the fallback method:

Gravatar::fallback('http://urlto.example.com/avatar.jpg')->get('[email protected]');

Recent Courses on Laravel Daily

Next.js Basics for Laravel Developers

11 lessons
58 min

Laravel 13 Eloquent: Expert Level

41 lessons
1 h 34 min

Queues in Laravel 13

18 lessons
1 h 12 min read

We'd Love Your Feedback

Tell us what you like or what we can improve

Feel free to share anything you like or dislike about this page or the platform in general.