Tags:
create new tag
, view all tags

Question

Is there an easy way to get the list of registered users for use in a form? I want a list box to be populated with their usernames

Environment

TWiki version: TWikiRelease02Sep2004
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: Linux
Web server: Apache
Perl version: 5.8.1
Client OS: Windows XP Pro
Web Browser: Internet Explorer
Categories: Forms

-- AlanJohnson - 28 Jun 2005

Answer

See UserInfoPlugin. You may have to paste some HTML around it.

-- AntonAylward - 28 Jun 2005

Or you can use a SEARCH:

<form name="testing" action="%SCRIPTURL%/view%SCRIPTSUFFIX%/%MAINWEB%" method="get">
<select name="topic">
<option>Select user...</option>
%SEARCH{ "Name:;Email:;Country:" web="%MAINWEB%" type="regex" nosearch="on" nototal="on" format="<option>$topic</option>" }%
</select>
<input type="submit" value="Go" />
</form>

Which expands to this: (here limited to all Z* users because TWiki.org has so many)

This searches all topics in the Main web that contain "Name", "Email" and "Country" bullets. Alternatively, do a FormattedSearch with multiple="on" on the Main.TWikiUsers topic.

-- PeterThoeny - 29 Jun 2005

 
Topic revision: r3 - 2005-06-29 - PeterThoeny
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.