Html.UrlLink() extension adds port 25 to email url

Found in

EPiServer.CMS.Core 7.0.586.0

Fixed in

EPiServer.CMS.Core 11.2.0


Oct 09, 2017


Nov 27, 2017


CMS Core


Closed, Fixed and tested


Html.UrlLink() extension adds port 25 after email address when rendering an email link on a web page.

Step to reproduce

  1. Add a property of type EPiServer.Url to any page type, or block type.

public virtual Url Link { get; set; }

  1. Modify its view to render the added property with Html.UrlLink().

@Html.UrlLink(Model.CurrentPage.Link, "This is the link", new Dictionary<string, object>() { { "class", "btn" } })

  1. Start the site, go to EPiServer Edit mode and edit the Url property.
  2. Set its type to "email", with a sample value, then publish the page.
  3. Go to view mode to observe the result.

Expected: The email link is rendered correctly.
Actual: The email link has port 25 placed after the mail address.