/**
 * Hide email using a shortcode.
 * @param array  $atts    Shortcode attributes.
 * @param string $content The shortcode content. Should be an email address.
 *
 * @return string The obfuscated email address.
 */
function ts_email_obfuscate_shortcode($atts, $content = null)
{
    extract(shortcode_atts(array('to' => $content, 'name' => $content, 'class' => false), $atts, 'email'));
    if (!is_email($to)) {
        return $content;
    }
    return ts_obfuscate_email($to, $name, $class);
}
 public static function e($to, $size, $shape, $use_fa)
 {
     $n = $use_fa ? self::f('email', $size, $shape) : self::i('email', $size, $shape);
     $c = '';
     if ($use_fa) {
         $c .= 'btn btn-social';
         $c .= ' btn-email';
         $c .= ' sl-' . ($shape == '' ? 'square' : $shape);
         $c .= ' sl-' . $size;
     } else {
         $c .= 'sl-img ';
     }
     $c .= ' sl-email';
     echo ts_obfuscate_email($to, $n, $c, 'nofollow');
 }