Simple Gravatar avatars for Textpattern.
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.



Simple Gravatarjcp_simple_gravatar — is a Textpattern plugin that simplifies the use of Gravatar avatars on your Textpattern site.


  1. Installation
  2. How to use
  3. Example use
  4. Information
  5. Source
  6. Bugs, issues or any other problems?



How to install Simple Gravatar.

How to use

Use <txp:jcp_simple_gravatar /> in your templates. It will return the gravatar URL.

There are four attributes, and all are optional;

email — custom email address for gravatar (if not specified, the plugin uses the comment author’s email)
user — get user’s gravatar (input: the user’s username)
default — default avatar, if no gravatar was found
default_local — default avatar. A local file, like images/9.png, that becomes (good for development)
size — the image size, in pixels (default: 80)
format — the file format, like .jpg or .png, without the dot (default: jpg)
where — is the gravatar in an article or in a comment? This is completely optional, Simple Gravatar can pick the right one for you.

Example use

In the comments form:

<img src="<txp:jcp_simple_gravatar default="" size="50" format="png" />" width="50" height="50" />

May return:

<img src="" width="50" height="50" />

In an article:

Author: <txp:author /><br />
<img src="<txp:jcp_simple_gravatar default_local="/images/6.png" size="60" />" />

May return:

Author: Andrew Dorsey<br />
<img src="" width="60" height="60" />

Get user’s avatar:

About Andrew:<br />
<img src="<txp:jcp_simple_gravatar user="andrew" />" />

May return:

About Andrew:<br />
<img src="" />


Simple Gravatar for Textpattern is based on the glx_gravatar plugin by Patrick Kollitsch, and is licensed under the GNU General Public License v2.



Bugs, issues or any other problems?

Please email me at jocapriconne at