[wp-trac] [WordPress Trac] #64973: Search block converts quotation marks to ampersand entity in prefilled value after search

WordPress Trac noreply at wordpress.org
Fri Mar 27 21:37:21 UTC 2026


#64973: Search block converts quotation marks to ampersand entity in prefilled
value after search
--------------------------+-----------------------------
 Reporter:  room34alt     |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Text Changes  |    Version:  6.9.4
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 When the Search block is present on the page that displays search results,
 the text the user entered in their search is prefilled in the form when
 displaying the search results.

 This is great, but I've noticed that if you search a phrase by putting it
 in quotation marks, the quotation marks are rendered in the search input
 field as `"` (the ampersand entity for a quotation mark) instead of
 `"` after submitting the search.

 This is happening because the actual string in the value attribute of the
 input field HTML is `"`; in other words, it's being double-
 escaped.

 (I'm probably selecting the wrong "Component" on this ticket but I'm not
 sure where it really should go.)

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


More information about the wp-trac mailing list