Last active
August 29, 2015 14:27
-
-
Save asharirfan/4c796ca147ea0e75f521 to your computer and use it in GitHub Desktop.
Gravatar Image WP Custom Function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravatar Image WP Custom Function | |
* @param string $aa_email user/author email address | |
* @param string $aa_size size of gravatar | |
* @return string gravatar image url | |
*/ | |
function aa_get_gravatar($aa_email, $aa_size) { | |
// Convert email into md5 hash and set image size to 200 px | |
$aa_gravatar_url = 'http://www.gravatar.com/avatar/' . md5($aa_email) . '?s=' . $aa_size; | |
return $aa_gravatar_url; | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment