Example #1
0
        static string Photo(string email)
        {
            var pf = AuthorProfile.GetProfileByEmail(email) ?? new AuthorProfile();

            if (string.IsNullOrEmpty(pf.PhotoUrl))
            {
                return("");
            }

            var img = pf.PhotoUrl.Replace("\"", "");

            return(img.StartsWith("http://") || img.StartsWith("https://") ? img :
                   Utils.RelativeWebRoot + "image.axd?picture=/avatars/" + img);
        }