In TWikiRegistration has a JavaScript construct that converts something an uneducated (non Wiki aware) user might type in (like "dns problem") and converts it into a wikiword ("DnsProblem").
Change
So I have componentised this so that it can be used elsewhere. I'm thinking on forms, expecially those that have contact with newbies before they have got the (or indeed, will ever care about the) wiki movement.
Benefits
This:
Make the code where constraint is needed more readable
Facilitates this functionality appearing elsewhere
Ensures that this functionality appears consistantly, leading to a more usable (and potentially more consistant) experience for users.
To include other fields on the same form one has to get Comment to emit no form. The attached CommentPluginNoForm.txt patch for /lib/TWiki/Plugins/CommentPlugin/Comment.pm drops the constructed form if noform="on" is present.
Credits
Crawford, again! For CommentPlugin!
-- MartinCleaver - 30 Sep 2004
Could you tell us a bit more on how to use this on other pages? Was TopicNameConstrainer already a setting in CommentsPlugin?
-- ArthurClemens - 30 Sep 2004
Sure. This is how I use it: