DokuWiki

It's better when it's simple

User Tools

Site Tools


devel:event:common_user_link

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
devel:event:common_user_link [2014-03-16 23:23] – created Klap-indevel:event:common_user_link [2018-12-08 15:07] (current) – doc updated according to issue #2615 torpedo
Line 1: Line 1:
 ====== COMMON_USER_LINK ====== ====== COMMON_USER_LINK ======
- 
-[[devel:develonly]] 
  
 ---- dataentry event ---- ---- dataentry event ----
Line 10: Line 8:
 ---- ----
  
-When the [[showuseras]] config is set to the user interwiki link, this event is signalled by [[xref>userlink()]] in [[xref>inc/common.php]]. Handlers can use it to implement there own formatted user name instead of the user interwiki link.+When the [[config:showuseras]] config is set to the user interwiki link, this event is signalled by [[xref>userlink()]] in [[xref>inc/common.php]]. Handlers can use it to implement their own formatted user name instead of the user [[:interwiki]] link.
  
 ===== Passed Data ===== ===== Passed Data =====
 +The passed [[xref>Doku_Event]] object has the field: ''$data''.
  
-The passed $data structure:+The ''$data'' field is an array with the structure:
  
   * ''$data['username']'' The unique user name   * ''$data['username']'' The unique user name
   * ''$data['name']'' The name of the user which is used as the name of the link   * ''$data['name']'' The name of the user which is used as the name of the link
-  * ''$data['link']'' Array with link properties which will be rendered by [[xref>_formatLink()]], or false to disables link creation+  * ''$data['link']'' Array with link properties which will be rendered by [[xref>_formatLink()]]. 
-  * ''$data['userlink']'' Formatted user name as will be returned by [[xref>userlink()]]+  * ''$data['userlink']'' The formatted user name as will be returned by [[xref>userlink()]]
   * ''$data['textonly']'' false: return html output, true: return plain text output   * ''$data['textonly']'' false: return html output, true: return plain text output
  
 +The BEFORE event has only the ''username'' and ''textonly'' fields filled. The AFTER event has all field filled.
    
-===== Plugins handling this event ===== +After that the COMMON_USER_LINK event is handled, the formatted user name stored in ''$data['userlink']'' will be returned  by [[xref>userlink()]].
- +
-The following plugins are known to handle this event and their source code may be a good start for understanding and implementing a handler yourself.+
  
-  *  
  
 ===== See also ===== ===== See also =====
  
-  * The [[config:showuseras]] config let you choice the user interwiki as user link format.  +  * [[codesearch>COMMON_USER_LINK|Code related to this event]] used in any DokuWiki's files, plugins and templates 
-  * Default the [[:interwiki|Interwiki]] user link is configured to points to '':user:<username>''.+  * The [[config:showuseras]] config let you choice the user interwiki link as the user link format.  
 +  * Default the user [[:interwiki|interwiki]] link is configured to refer to '':user:<username>''.
   * [[devel:Action Plugins]]   * [[devel:Action Plugins]]
   * [[devel:Events]]   * [[devel:Events]]
devel/event/common_user_link.1395008636.txt.gz · Last modified: 2014-03-16 23:23 by Klap-in

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