Last Comment Bug 795272 - Non-breaking spaces in H tags are encoded in the id attribute, would probably be better to make underscore
: Non-breaking spaces in H tags are encoded in the id attribute, would probably...
Product: Mozilla Developer Network
Classification: Other
Component: Editing (show other bugs)
: unspecified
: All All
P2 normal with 2 votes (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
: website
: 801062 (view as bug list)
Depends on:
  Show dependency treegraph
Reported: 2012-09-28 04:16 PDT by Trevor
Modified: 2014-10-01 06:47 PDT (History)
2 users (show)
See Also:
QA Whiteboard:
Iteration: ---
Points: ---

kuma-Bug795272_Non-breaking_spaces.patch (867 bytes, patch)
2013-09-14 01:13 PDT, Trevor
no flags Details | Diff | Splinter Review

Description User image Trevor 2012-09-28 04:16:36 PDT
Entering <h3>DOM&nbsp;Interface</h3> and saving results in <h3 id="DOM.C2.A0Interface">DOM&nbsp;Interface</h3>

It would probably be better if the non-breaking space was treated as a regular space and converted to an underscore in the id.
Comment 1 User image Trevor 2012-09-28 04:17:29 PDT
This probably applies to all ids created from content.
Comment 2 User image Florian Scholz [:fscholz] (MDN) 2012-10-12 12:46:36 PDT
*** Bug 801062 has been marked as a duplicate of this bug. ***
Comment 3 User image Trevor 2013-09-14 01:13:40 PDT
Created attachment 804852 [details] [diff] [review]
Comment 4 User image Eric Shepherd [:sheppy] 2014-04-24 11:27:32 PDT
Trevor is right; we always convert spaces to underscores in URLs on MDN, so that's how this should work here too.
Comment 5 User image [github robot] 2014-10-01 06:47:21 PDT
Commits pushed to master at
fix bug 795272 - Convert non-breaking spaces in header ids to underscores
Merge pull request #2785 from trevorhobson/bug795272

Bug 795272 - Convert non-breaking spaces in headers ids to underscores

Note You need to log in before you can comment on or make changes to this bug.