FAQ:

How can I re-build my Wiki Users topic?

Answer:

ALERT! Under normal circumstances, there should be no need to rebuild your Wiki Users topic.

Sometimes, the Wiki Users topic maintained by Topic User Mapping Contrib may not reflect the true list of users registered on your Foswiki installation. This most commonly happens when:

  • You deleted or renamed users and forgot to edit the Wiki Users topic, or
  • You migrated a TWiki installation and accumulated new registrations on the new Wiki Users topic before you had a chance to initialise it with the old list from the old TWikiUsers topic.

Assuming your wiki is configured to use Topic User Mapping Contrib, the script below should refresh your Wiki Users topic with an accurate list of users. It uses the USERINFO macro, which protects user information from ordinary users - so this topic needs to be viewed with admin privileges in order for it to be useful.

%STARTSECTION{"WIKIUSERS"}%
%FORMAT{"A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z" 
    type="string" 
    format="   * $item - <a name='$item'>- - - -</a> $percentINCLUDE{
        \"%TOPIC%\"
        section=\"USERS\"
        letter=\"$item\"
    }$percent" 
}% 
%ENDSECTION{"WIKIUSERS"}%

%STARTSECTION{"USERS"}%%SEARCH{
    "name=~'^%letter%.*' AND (form.name~'*UserForm')"
    type="query"
    web="%USERSWEB%"
    nonoise="on"
    header="$n"
    format="   * $percentUSERINFO{
        \"$topic\"
        format=\"$dollarwikiname - $dollarusername\"
    }$percent - $createdate"
}%%ENDSECTION{"USERS"}% 

Back to: FrequentlyAskedQuestion


Related Topics: Foswiki:Support.Faq27, Topic User Mapping Contrib, Wiki Users, Admin Documentation Category