DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:goto:supplement

This is an old revision of the document!


<= goto

Temporary download

https://github.com/turnermm/goto/archive/user.zip

See the configuration options for how to configure the page to which the user is redirected.

To install, use the Manual Install tab of the Extension Manager. Paste one of the above links into the url box and click Install. You can also download and unzip the file in your wiki's lib/plugins directory, and then rename the new directory to goto.

Auto Login

Auto login enables registered users, on logging into the wiki, to be automatically redirected to their own user page. There are two ways to implement the auto login feature.

1. Embedded GOTO Syntax

The first uses the GOTO syntax with the user wildcard in place of the page id:

  ~~GOTO:user~~ 

This must be placed on the wiki's main page, so that when the user logs in, the page displayed in the browser is the page with this markup. No message is printed to the screen. and the user is redirected to the user page in the root namespace. If the userid is “foo”, the user page will be “:foo”. This does not take a time setting: ?tm. The redirection occurs after 1 second delay on login.

2. Configured Background Process

Unlike 1 this method requires no additional plugin markup. On login, the auto login feature redirects the user to the user's page or start page. This page and its namespace are based on the settings in either the auto_options setting or the group_options setting. For this to work, the auto_login option must be set to true. The redirection occurs immediately, without a delay.

The redirects are governed by the auto_options and group_optons settings. The auto_options redirect to pages and namespaces based on the userid. The group_options redirect to pages located in namespaces based on group membership.

Configuration

OptionDescriptionDefault
secondsTime till redirection (seconds) 3
minSecondsMinimum time allowed till redirection (seconds) 2
auto_loginOn login, automatically go to predefined page, as set in auto_options false
auto_optionsTarget for the auto_login page(See auto_options):user_page
common_ns1)Used with auto_options. Arbitrarily defined namespace of any depth where the auto login pages will reside. This can include the wildcard user_ns, in which case the user will have a namespace in the common namespace directory.
groupComma separated list of group namespaces to which users can be redirected. Different users can be in different groups. If a user belongs to two groups on this list, the user will be redirected to the first.
group_optionsThe user can be redirected either to the group start page or to the user's own page in the group namespace. The options are start_page dnd user_pagestart_page
only_optionThe options are group and user. group restricts redirects only to group namespaces and their pages; user only to user namespaces and pages; and default to either, with group having precedence.default

Auto_Options

There a four options available for defining the user page and namespace to which the auto login will be directed. In each case user stands for the userid and ns for namespace. If the userid is “foo”, then the first option would give you “:foo” in the root namespace, the second option “:foo:foo”. The start page is one of DokuWiki's basic configurations and defaults to start. The fourth option requires that the GOTO common namespace (common_ns) option be set. These are the four possibilities for defining the auto login page, whwere “foo” is the userid:

  1. :user_page
    :foo
  2. :user_ns:user_page
    :foo:foo
  3. :user_ns:start_page
    foo:start
  4. :common_ns:user_page
    <common_ns>:foo 2)

Group Options

Therre are two possibilities for defining the auto login page based on group membership. In each case the group name is the name of the namespace so that both options locate the redirect page in a namespace which is the same as the group name:

  1. start_page
    group-name:start
  2. user_page
    group-name:userid

External links now supported in the extern branch, which also includes the auto-login features.

1)
i.e. common namespace, so named because it is common to all users.
plugin/goto/supplement.1553267622.txt.gz · Last modified: 2019-03-22 16:13 by turnermm

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki