create new tag
, view all tags

SID-02156: Prevent non-WikiWords in Topic Names

Status: Asked Asked TWiki version: 6.0.2 Perl version:
Category: CategoryEditing Server OS: Ubuntu Linux Last update: 1 year ago

I have found that renaming topics and webs with single word-names to be problematic.

And even though I tell my users not to do it, they still name topics and webs with single words ("Beef" rather than "DeadBeef", and so on).

Is there any way to prevent, without exception, single-word topic and web names from even being created? I've looked for a preference or a plugin, but I'm not finding anything.

-- TWiki Guest - 2016-02-22

Discussion and Answer

I don't know of a way to absolutely prevent creation of single-word topics without altering the code - after all, it is a feature of TWiki to allow single-word topics if desired. However, you can make it "difficult" to create such topics by customizing the interfaces: The scripts edit, rename and copy have parameters to enforce wiki names. Usually, users don't enter URLs to these scripts manually, they rather use TWiki's user interface to create new topics (WebCreateNewTopic) or to rename/copy ("More topic actions"). Whether the user interface shows the parameter to allow single-word topics or not is just a matter of the corresponding TWiki templates - or a skin - which can be customized. Documentation is in TWikiTemplates and TWikiSkins - I admit that I am not an expert on that matter.

For single-word webs - that's different. TWiki's own webs like TWiki, Support, Sandbox all are single-word names. I don't think web names can be enforced to be wiki names.

-- Harald Jörg - 2016-02-23

Thanks, Harald. That's too bad, since I have found that the TWiki renamer does, essentially, a find/replace on the Web name if I rename a Web. If I had a Web named "Guest", for instance, and decided to rename it to "SomethingElse", then every occurrence of the string "Guest" gets replaced with "SomethingElse", whether it is part of a URI or not. It's a real problem!

-- TWiki Guest - 2016-02-24

If renaming a web renames unrelated text you found a bug. Please file a bug report at TWikibug:WebHome if you can describe this in a reproducible manner.

-- Peter Thoeny - 2016-02-26

      Change status to:
ALERT! 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.
Status Asked
Title Prevent non-WikiWords in Topic Names
SupportCategory CategoryEditing
TWiki version 6.0.2
Server OS Ubuntu Linux
Web server Apache
Perl version

Browser & version

Edit | Attach | Watch | Print version | History: r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r4 - 2016-02-26 - PeterThoeny
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.