leiger wrote on 15 Nov 2009 02:49
This is a design sketch for "automatic code replacement", which is a technique to save users effort when typing complex wiki syntax.
The settings are configured per-site, by the site admins.
The admin supplies two values:
When someone saves a page or comment, their code is cross-referenced with this list. If any of the code matches what is provided in the "code" column, then it is replaced with the corresponding "replace with" code at runtime.
The site manager setting might look like this after a few entries have been made:
||[[include youtube |video_id=
This means that if someone was to type [b]Hello[/b] into the source code, it would do the same thing as **Hello** does (making the text style = bold).
Note: [b]Hello[b] and [/b]Hello[/b] would also work!
If someone were to type [youtube]_6nfVLOsj6U[/youtube], then it would convert to this: [[include youtube |video_id=_6nfVLOsj6U]] (and that included page contains code for embedding a youtube video… e.g. dimensions of the player, etc.
Start a new sub-thread
We discourage direct comments on this thread: to discuss it, please start a sub-thread.
page revision: 13, last edited: 19 Mar 2010 11:23