Changes between Version 3 and Version 4 of Documentation/Plugins/Linker


Ignore:
Timestamp:
09/13/06 16:15:10 (13 years ago)
Author:
gogo
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Documentation/Plugins/Linker

    v3 v4  
    66 
    77Linker plugin displays a Tree where the user can select the file he wants to link. 
    8 Currently there are two methods for filling this tree: 
     8Currently there are three methods for filling this tree: 
    99 
    10 === 1. using an external backend-file === 
    11 (default, returns all files found in DOCUMENT_ROOT) 
     10=== 1. using the provided backend scanner === 
     11By default Linker provides a tree listing files under the xinha directory itself, not that useful generally so if you wish to control scan.php it can be configured similarly to ImageManager ... 
    1212{{{ 
    13 editor.config.Linker.backend = _editor_url + 'plugins/Linker/scan.php'; 
     13  with(xinha_config.Linker) 
     14  { 
     15    <?php  
     16      require_once('/path/to/xinha/contrib/php-xinha.php'); 
     17      xinha_pass_to_php_backend 
     18      ( 
     19         array( 
     20          'dir' => '/path/to/base/dir', 
     21          'include' => '/\.(php|shtml|html|htm|shtm|cgi|txt|doc|pdf|rtf|xls|csv)$/',  // REGEXP or empty 
     22          'exclude' => '', // REGEXP or empty 
     23          'dirinclude' => '', // REGEXP  or empty 
     24          'direxclude' => '/(^|\/)[._]|htmlarea/' // REGEXP or empty 
     25         )  
     26      ); 
     27    ?> 
     28  } 
    1429}}} 
     30 
     31=== 2. Write your own scan.php === 
     32 
     33{{{ 
     34editor.config.Linker.backend = '/url/to/your/scan.php'; 
     35}}} 
     36 
     37 
    1538scan.php should return code like this one: 
    1639{{{ 
     
    2851] 
    2952}}} 
     53 
    3054Type 3 and 4 nodes would be the preference, I'd go so far as to deprecate type 1 and 2. 
    3155 
    32 === 2. using configuration-variables === 
     56=== 3. using configuration-variables === 
    3357{{{ 
    3458editor.config.Linker.backend = null;