Question
Hi to all!!!
I have a question here regarding wiki words in html forms. I have a field and the user must supply a wiki word in that field. How do I check if the value supplied by the user is indeed a wiki word? Any javascript for this. If the word is not a wiki word, i could then prompt the user an alert that the value given is invalid. If not a javascript, how could I do that in an embedded html using an onsubmit event? Any ideas is greatly appreciated. Many Thanks!
Environment
--
MartinJrAdane - 01 Aug 2006
Answer
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
Look at the source of
TWikiRegistration, it uses
JavaScript to create a
WikiWord out of the user name. You can leverage that for your WikiWord test.
--
PeterThoeny - 01 Sep 2006
The
JavaScript file
twiki.js
that is distributed with TWiki 4 has a function to check for a wikiword:
isWikiWord. See for example the latest
WebTopicCreator
where this script is being used to provide user feedback.
--
ArthurClemens - 01 Sep 2006