private static string GetImageTag(string imagePath, string altText) { UrlString url = new UrlString(imagePath); string xhtmlImageUrl = url.GetUrl(true); if (!string.IsNullOrEmpty(imagePath) && !string.IsNullOrEmpty(altText)) { return(string.Format("<img src=\"{0}\" alt=\"{1}\" />", xhtmlImageUrl, altText)); } if (!string.IsNullOrEmpty(imagePath)) { return(string.Format("<img src=\"{0}\" />", xhtmlImageUrl)); } return(string.Empty); }
public void Append(UrlString url) { Assert.EnsureNotNullReference(url, "url"); this.Append(url.Parameters); }
private static string GetImageTag(string imagePath, string altText) { UrlString url = new UrlString(imagePath); string xhtmlImageUrl = url.GetUrl(true); if (!string.IsNullOrEmpty(imagePath) && !string.IsNullOrEmpty(altText)) { return string.Format("<img src=\"{0}\" alt=\"{1}\" />", xhtmlImageUrl, altText); } if (!string.IsNullOrEmpty(imagePath)) { return string.Format("<img src=\"{0}\" />", xhtmlImageUrl); } return string.Empty; }