1 (edited by nakome 2012-10-05 22:15:48)

Topic: Simple Gravatar snippet

Simple Gravatar snippet

  <?php function addGravatar(){

     $url = 'http://www.gravatar.com/avatar/';
     $email =  '   your email here  ';  // email 
     $default = 'monsterid';
     $size = 75;  // size                       
    $gravatar = $url.'?gravatar_id='.md5( strtolower($email) ).'&default='.urlencode($default).'&size='.$size; 
                        
    echo ('<img src="'.$gravatar.'" />'); }?>
                        
   <?php addGravatar();?>
..::: Moncho Varela ::::..   ..::: @Nakome ::::..   ..::: Github ::::..