[wp-trac] [WordPress Trac] #65416: Linking text containing a colon breaks the URL

WordPress Trac noreply at wordpress.org
Fri Jun 5 05:16:47 UTC 2026


#65416: Linking text containing a colon breaks the URL
-------------------------------------------------+-------------------------
 Reporter:  proleads                             |      Owner:  (none)
     Type:  defect (bug)                         |     Status:  new
 Priority:  normal                               |  Milestone:  Awaiting
                                                 |  Review
Component:  Post Formats                         |    Version:  7.0
 Severity:  normal                               |   Keywords:
  Focuses:  javascript, coding-standards, php-   |
  compatibility                                  |
-------------------------------------------------+-------------------------
 When creating a link where the linked text itself contains a colon (:),
 WordPress incorrectly interprets the text after the colon as part of the
 URL.

 Steps to reproduce:
 1.Create or edit a post/page.
 2.Add a hyperlink.
 3.Use linked text containing a colon, for example:

 Example: text

 4.Insert a normal HTTPS URL.

 Expected behavior:
 The linked text should remain unchanged, while the URL should only contain
 the actual hyperlink target.

 Actual behavior:
 WordPress incorrectly includes the text after the colon in the generated
 link, resulting in malformed URLs.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/65416>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list