summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMichael Hamann <michael@content-space.de>2011-01-23 20:33:32 +0100
committerMichael Hamann <michael@content-space.de>2011-01-23 20:33:32 +0100
commitfc756e0d4d88b37c01a9155e675a549430b00593 (patch)
tree7adc185d2c349788961ff7cb8f9bcb25afbce485 /lib
parent8605afb1b4e2a6a9e11e21a7bf0775bbb0d5af03 (diff)
parent820923f1328bcfe6002831570eb65238411c5b70 (diff)
downloadrpg-fc756e0d4d88b37c01a9155e675a549430b00593.tar.gz
rpg-fc756e0d4d88b37c01a9155e675a549430b00593.tar.bz2
Merge branch 'master' into indexer_improvements
Conflicts: inc/fulltext.php inc/indexer.php lib/exe/indexer.php
Diffstat (limited to 'lib')
-rw-r--r--lib/exe/ajax.php458
-rw-r--r--lib/exe/css.php31
-rw-r--r--lib/exe/fetch.php2
-rw-r--r--lib/exe/indexer.php48
-rw-r--r--lib/exe/js.php2
-rw-r--r--lib/exe/opensearch.php2
-rw-r--r--lib/exe/xmlrpc.php45
-rw-r--r--lib/images/interwiki/paypal.gifbin0 -> 942 bytes
-rw-r--r--lib/images/interwiki/sb.gifbin886 -> 1000 bytes
-rw-r--r--lib/plugins/acl/admin.php2
-rw-r--r--lib/plugins/acl/lang/de-informal/lang.php1
-rw-r--r--lib/plugins/acl/lang/de/lang.php2
-rw-r--r--lib/plugins/acl/lang/en/lang.php2
-rw-r--r--lib/plugins/acl/lang/et/lang.php2
-rw-r--r--lib/plugins/acl/lang/he/lang.php1
-rw-r--r--lib/plugins/acl/lang/ko/lang.php1
-rw-r--r--lib/plugins/acl/lang/la/help.txt4
-rw-r--r--lib/plugins/acl/lang/la/lang.php19
-rw-r--r--lib/plugins/acl/lang/ru/help.txt16
-rw-r--r--lib/plugins/acl/lang/ru/lang.php2
-rw-r--r--lib/plugins/acl/lang/sl/lang.php15
-rw-r--r--lib/plugins/acl/lang/tr/lang.php5
-rw-r--r--lib/plugins/acl/lang/vi/lang.php2
-rw-r--r--lib/plugins/admin.php2
-rw-r--r--lib/plugins/config/lang/ar/lang.php9
-rw-r--r--lib/plugins/config/lang/cs/intro.txt2
-rw-r--r--lib/plugins/config/lang/cs/lang.php10
-rw-r--r--lib/plugins/config/lang/de-informal/lang.php2
-rw-r--r--lib/plugins/config/lang/de/lang.php3
-rw-r--r--lib/plugins/config/lang/en/lang.php1
-rw-r--r--lib/plugins/config/lang/he/lang.php1
-rw-r--r--lib/plugins/config/lang/ko/lang.php8
-rw-r--r--lib/plugins/config/lang/la/intro.txt4
-rw-r--r--lib/plugins/config/lang/la/lang.php23
-rw-r--r--lib/plugins/config/lang/ru/intro.txt4
-rw-r--r--lib/plugins/config/lang/ru/lang.php49
-rw-r--r--lib/plugins/config/lang/sl/lang.php1
-rw-r--r--lib/plugins/config/lang/tr/lang.php5
-rw-r--r--lib/plugins/config/settings/config.class.php25
-rw-r--r--lib/plugins/config/settings/config.metadata.php8
-rw-r--r--lib/plugins/info/syntax.php2
-rw-r--r--lib/plugins/plugin/lang/cs/lang.php4
-rw-r--r--lib/plugins/plugin/lang/de-informal/lang.php1
-rw-r--r--lib/plugins/plugin/lang/de/lang.php2
-rw-r--r--lib/plugins/plugin/lang/en/lang.php2
-rw-r--r--lib/plugins/plugin/lang/he/lang.php1
-rw-r--r--lib/plugins/plugin/lang/ko/lang.php1
-rw-r--r--lib/plugins/plugin/lang/la/admin_plugin.txt2
-rw-r--r--lib/plugins/plugin/lang/la/lang.php3
-rw-r--r--lib/plugins/plugin/lang/pt-br/admin_plugin.txt2
-rw-r--r--lib/plugins/plugin/lang/ru/lang.php8
-rw-r--r--lib/plugins/plugin/lang/sl/lang.php1
-rw-r--r--lib/plugins/plugin/lang/tr/lang.php5
-rw-r--r--lib/plugins/popularity/action.php57
-rw-r--r--lib/plugins/popularity/admin.php277
-rw-r--r--lib/plugins/popularity/helper.php291
-rw-r--r--lib/plugins/popularity/lang/ar/lang.php5
-rw-r--r--lib/plugins/popularity/lang/ar/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/cs/intro.txt2
-rw-r--r--lib/plugins/popularity/lang/de-informal/lang.php6
-rw-r--r--lib/plugins/popularity/lang/de-informal/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/de/lang.php7
-rw-r--r--lib/plugins/popularity/lang/de/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/en/lang.php9
-rw-r--r--lib/plugins/popularity/lang/en/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/es/lang.php5
-rw-r--r--lib/plugins/popularity/lang/es/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/he/lang.php1
-rw-r--r--lib/plugins/popularity/lang/ko/lang.php1
-rw-r--r--lib/plugins/popularity/lang/la/intro.txt9
-rw-r--r--lib/plugins/popularity/lang/la/lang.php6
-rw-r--r--lib/plugins/popularity/lang/la/submitted.txt3
-rw-r--r--lib/plugins/popularity/lang/ru/intro.txt6
-rw-r--r--lib/plugins/popularity/lang/ru/lang.php5
-rw-r--r--lib/plugins/popularity/lang/sl/lang.php1
-rw-r--r--lib/plugins/popularity/lang/tr/lang.php5
-rw-r--r--lib/plugins/popularity/plugin.info.txt7
-rw-r--r--lib/plugins/revert/admin.php2
-rw-r--r--lib/plugins/revert/lang/cs/intro.txt2
-rw-r--r--lib/plugins/revert/lang/de-informal/lang.php1
-rw-r--r--lib/plugins/revert/lang/de/lang.php2
-rw-r--r--lib/plugins/revert/lang/en/lang.php2
-rw-r--r--lib/plugins/revert/lang/he/lang.php1
-rw-r--r--lib/plugins/revert/lang/ko/lang.php1
-rw-r--r--lib/plugins/revert/lang/la/intro.txt2
-rw-r--r--lib/plugins/revert/lang/la/lang.php1
-rw-r--r--lib/plugins/revert/lang/ru/intro.txt2
-rw-r--r--lib/plugins/revert/lang/sl/lang.php1
-rw-r--r--lib/plugins/revert/lang/tr/lang.php5
-rw-r--r--lib/plugins/syntax.php13
-rw-r--r--lib/plugins/usermanager/lang/cs/lang.php2
-rw-r--r--lib/plugins/usermanager/lang/de-informal/lang.php1
-rw-r--r--lib/plugins/usermanager/lang/de/lang.php2
-rw-r--r--lib/plugins/usermanager/lang/he/lang.php1
-rw-r--r--lib/plugins/usermanager/lang/ko/lang.php1
-rw-r--r--lib/plugins/usermanager/lang/la/lang.php1
-rw-r--r--lib/plugins/usermanager/lang/ru/lang.php4
-rw-r--r--lib/plugins/usermanager/lang/sl/lang.php18
-rw-r--r--lib/plugins/usermanager/lang/tr/lang.php5
-rw-r--r--lib/scripts/ajax.js126
-rw-r--r--lib/tpl/default/rtl.css3
101 files changed, 1126 insertions, 644 deletions
diff --git a/lib/exe/ajax.php b/lib/exe/ajax.php
index e9c59ca5d..1939a7bcb 100644
--- a/lib/exe/ajax.php
+++ b/lib/exe/ajax.php
@@ -8,7 +8,7 @@
//fix for Opera XMLHttpRequests
if(!count($_POST) && !empty($HTTP_RAW_POST_DATA)){
- parse_str($HTTP_RAW_POST_DATA, $_POST);
+ parse_str($HTTP_RAW_POST_DATA, $_POST);
}
if(!defined('DOKU_INC')) define('DOKU_INC',dirname(__FILE__).'/../../');
@@ -20,25 +20,25 @@ header('Content-Type: text/html; charset=utf-8');
//call the requested function
-if(isset($_POST['call']))
- $call = $_POST['call'];
-else if(isset($_GET['call']))
- $call = $_GET['call'];
-else
- exit;
-
+if(isset($_POST['call'])){
+ $call = $_POST['call'];
+}else if(isset($_GET['call'])){
+ $call = $_GET['call'];
+}else{
+ exit;
+}
$callfn = 'ajax_'.$call;
if(function_exists($callfn)){
- $callfn();
+ $callfn();
}else{
- $evt = new Doku_Event('AJAX_CALL_UNKNOWN', $call);
- if ($evt->advise_before()) {
- print "AJAX call '".htmlspecialchars($call)."' unknown!\n";
- exit;
- }
- $evt->advise_after();
- unset($evt);
+ $evt = new Doku_Event('AJAX_CALL_UNKNOWN', $call);
+ if ($evt->advise_before()) {
+ print "AJAX call '".htmlspecialchars($call)."' unknown!\n";
+ exit;
+ }
+ $evt->advise_after();
+ unset($evt);
}
/**
@@ -47,33 +47,33 @@ if(function_exists($callfn)){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function ajax_qsearch(){
- global $conf;
- global $lang;
-
- $query = $_POST['q'];
- if(empty($query)) $query = $_GET['q'];
- if(empty($query)) return;
-
- $data = ft_pageLookup($query, true, useHeading('navigation'));
-
- if(!count($data)) return;
-
- print '<strong>'.$lang['quickhits'].'</strong>';
- print '<ul>';
- foreach($data as $id => $title){
- if (useHeading('navigation')) {
- $name = $title;
- } else {
- $ns = getNS($id);
- if($ns){
- $name = shorten(noNS($id), ' ('.$ns.')',30);
- }else{
- $name = $id;
+ global $conf;
+ global $lang;
+
+ $query = $_POST['q'];
+ if(empty($query)) $query = $_GET['q'];
+ if(empty($query)) return;
+
+ $data = ft_pageLookup($query, true, useHeading('navigation'));
+
+ if(!count($data)) return;
+
+ print '<strong>'.$lang['quickhits'].'</strong>';
+ print '<ul>';
+ foreach($data as $id => $title){
+ if (useHeading('navigation')) {
+ $name = $title;
+ } else {
+ $ns = getNS($id);
+ if($ns){
+ $name = noNS($id).' ('.$ns.')';
+ }else{
+ $name = $id;
+ }
}
+ echo '<li>' . html_wikilink(':'.$id,$name) . '</li>';
}
- echo '<li>' . html_wikilink(':'.$id,$name) . '</li>';
- }
- print '</ul>';
+ print '</ul>';
}
/**
@@ -83,36 +83,36 @@ function ajax_qsearch(){
* @author Mike Frysinger <vapier@gentoo.org>
*/
function ajax_suggestions() {
- global $conf;
- global $lang;
-
- $query = cleanID($_POST['q']);
- if(empty($query)) $query = cleanID($_GET['q']);
- if(empty($query)) return;
-
- $data = array();
- $data = ft_pageLookup($query);
- if(!count($data)) return;
- $data = array_keys($data);
-
- // limit results to 15 hits
- $data = array_slice($data, 0, 15);
- $data = array_map('trim',$data);
- $data = array_map('noNS',$data);
- $data = array_unique($data);
- sort($data);
-
- /* now construct a json */
- $suggestions = array(
- $query, // the original query
- $data, // some suggestions
- array(), // no description
- array() // no urls
- );
- $json = new JSON();
-
- header('Content-Type: application/x-suggestions+json');
- print $json->encode($suggestions);
+ global $conf;
+ global $lang;
+
+ $query = cleanID($_POST['q']);
+ if(empty($query)) $query = cleanID($_GET['q']);
+ if(empty($query)) return;
+
+ $data = array();
+ $data = ft_pageLookup($query);
+ if(!count($data)) return;
+ $data = array_keys($data);
+
+ // limit results to 15 hits
+ $data = array_slice($data, 0, 15);
+ $data = array_map('trim',$data);
+ $data = array_map('noNS',$data);
+ $data = array_unique($data);
+ sort($data);
+
+ /* now construct a json */
+ $suggestions = array(
+ $query, // the original query
+ $data, // some suggestions
+ array(), // no description
+ array() // no urls
+ );
+ $json = new JSON();
+
+ header('Content-Type: application/x-suggestions+json');
+ print $json->encode($suggestions);
}
/**
@@ -121,32 +121,32 @@ function ajax_suggestions() {
* Andreas Gohr <andi@splitbrain.org>
*/
function ajax_lock(){
- global $conf;
- global $lang;
- $id = cleanID($_POST['id']);
- if(empty($id)) return;
-
- if(!checklock($id)){
- lock($id);
- echo 1;
- }
-
- if($conf['usedraft'] && $_POST['wikitext']){
- $client = $_SERVER['REMOTE_USER'];
- if(!$client) $client = clientIP(true);
+ global $conf;
+ global $lang;
+ $id = cleanID($_POST['id']);
+ if(empty($id)) return;
+
+ if(!checklock($id)){
+ lock($id);
+ echo 1;
+ }
- $draft = array('id' => $id,
- 'prefix' => substr($_POST['prefix'], 0, -1),
- 'text' => $_POST['wikitext'],
- 'suffix' => $_POST['suffix'],
- 'date' => (int) $_POST['date'],
- 'client' => $client,
- );
- $cname = getCacheName($draft['client'].$id,'.draft');
- if(io_saveFile($cname,serialize($draft))){
- echo $lang['draftdate'].' '.dformat();
+ if($conf['usedraft'] && $_POST['wikitext']){
+ $client = $_SERVER['REMOTE_USER'];
+ if(!$client) $client = clientIP(true);
+
+ $draft = array('id' => $id,
+ 'prefix' => substr($_POST['prefix'], 0, -1),
+ 'text' => $_POST['wikitext'],
+ 'suffix' => $_POST['suffix'],
+ 'date' => (int) $_POST['date'],
+ 'client' => $client,
+ );
+ $cname = getCacheName($draft['client'].$id,'.draft');
+ if(io_saveFile($cname,serialize($draft))){
+ echo $lang['draftdate'].' '.dformat();
+ }
}
- }
}
@@ -156,14 +156,14 @@ function ajax_lock(){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function ajax_draftdel(){
- $id = cleanID($_REQUEST['id']);
- if(empty($id)) return;
+ $id = cleanID($_REQUEST['id']);
+ if(empty($id)) return;
- $client = $_SERVER['REMOTE_USER'];
- if(!$client) $client = clientIP(true);
+ $client = $_SERVER['REMOTE_USER'];
+ if(!$client) $client = clientIP(true);
- $cname = getCacheName($client.$id,'.draft');
- @unlink($cname);
+ $cname = getCacheName($client.$id,'.draft');
+ @unlink($cname);
}
/**
@@ -172,22 +172,22 @@ function ajax_draftdel(){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function ajax_medians(){
- global $conf;
-
- // wanted namespace
- $ns = cleanID($_POST['ns']);
- $dir = utf8_encodeFN(str_replace(':','/',$ns));
-
- $lvl = count(explode(':',$ns));
-
- $data = array();
- search($data,$conf['mediadir'],'search_index',array('nofiles' => true),$dir);
- foreach($data as $item){
- $item['level'] = $lvl+1;
- echo media_nstree_li($item);
- echo media_nstree_item($item);
- echo '</li>';
- }
+ global $conf;
+
+ // wanted namespace
+ $ns = cleanID($_POST['ns']);
+ $dir = utf8_encodeFN(str_replace(':','/',$ns));
+
+ $lvl = count(explode(':',$ns));
+
+ $data = array();
+ search($data,$conf['mediadir'],'search_index',array('nofiles' => true),$dir);
+ foreach($data as $item){
+ $item['level'] = $lvl+1;
+ echo media_nstree_li($item);
+ echo media_nstree_item($item);
+ echo '</li>';
+ }
}
/**
@@ -196,11 +196,11 @@ function ajax_medians(){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function ajax_medialist(){
- global $conf;
- global $NS;
+ global $conf;
+ global $NS;
- $NS = $_POST['ns'];
- tpl_mediaContent(true);
+ $NS = $_POST['ns'];
+ tpl_mediaContent(true);
}
/**
@@ -209,24 +209,24 @@ function ajax_medialist(){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function ajax_index(){
- global $conf;
-
- // wanted namespace
- $ns = cleanID($_POST['idx']);
- $dir = utf8_encodeFN(str_replace(':','/',$ns));
-
- $lvl = count(explode(':',$ns));
-
- $data = array();
- search($data,$conf['datadir'],'search_index',array('ns' => $ns),$dir);
- foreach($data as $item){
- $item['level'] = $lvl+1;
- echo html_li_index($item);
- echo '<div class="li">';
- echo html_list_index($item);
- echo '</div>';
- echo '</li>';
- }
+ global $conf;
+
+ // wanted namespace
+ $ns = cleanID($_POST['idx']);
+ $dir = utf8_encodeFN(str_replace(':','/',$ns));
+
+ $lvl = count(explode(':',$ns));
+
+ $data = array();
+ search($data,$conf['datadir'],'search_index',array('ns' => $ns),$dir);
+ foreach($data as $item){
+ $item['level'] = $lvl+1;
+ echo html_li_index($item);
+ echo '<div class="li">';
+ echo html_list_index($item);
+ echo '</div>';
+ echo '</li>';
+ }
}
/**
@@ -235,108 +235,106 @@ function ajax_index(){
* @author Andreas Gohr <gohr@cosmocode.de>
*/
function ajax_linkwiz(){
- global $conf;
- global $lang;
-
- $q = ltrim($_POST['q'],':');
- $id = noNS($q);
- $ns = getNS($q);
-
- $ns = cleanID($ns);
- $id = cleanID($id);
-
- $nsd = utf8_encodeFN(str_replace(':','/',$ns));
- $idd = utf8_encodeFN(str_replace(':','/',$id));
-
- $data = array();
- if($q && !$ns){
-
- // use index to lookup matching pages
- $pages = array();
- $pages = ft_pageLookup($id,true);
-
- // result contains matches in pages and namespaces
- // we now extract the matching namespaces to show
- // them seperately
- $dirs = array();
-
-
- foreach($pages as $pid => $title){
- if(strpos(noNS($pid),$id) === false){
- // match was in the namespace
- $dirs[getNS($pid)] = 1; // assoc array avoids dupes
- }else{
- // it is a matching page, add it to the result
- $data[] = array(
- 'id' => $pid,
- 'title' => $title,
- 'type' => 'f',
- );
- }
- unset($pages[$pid]);
- }
- foreach($dirs as $dir => $junk){
- $data[] = array(
- 'id' => $dir,
- 'type' => 'd',
- );
- }
+ global $conf;
+ global $lang;
+
+ $q = ltrim($_POST['q'],':');
+ $id = noNS($q);
+ $ns = getNS($q);
+
+ $ns = cleanID($ns);
+ $id = cleanID($id);
+
+ $nsd = utf8_encodeFN(str_replace(':','/',$ns));
+ $idd = utf8_encodeFN(str_replace(':','/',$id));
+
+ $data = array();
+ if($q && !$ns){
+
+ // use index to lookup matching pages
+ $pages = array();
+ $pages = ft_pageLookup($id,true);
+
+ // result contains matches in pages and namespaces
+ // we now extract the matching namespaces to show
+ // them seperately
+ $dirs = array();
+
+ foreach($pages as $pid => $title){
+ if(strpos(noNS($pid),$id) === false){
+ // match was in the namespace
+ $dirs[getNS($pid)] = 1; // assoc array avoids dupes
+ }else{
+ // it is a matching page, add it to the result
+ $data[] = array(
+ 'id' => $pid,
+ 'title' => $title,
+ 'type' => 'f',
+ );
+ }
+ unset($pages[$pid]);
+ }
+ foreach($dirs as $dir => $junk){
+ $data[] = array(
+ 'id' => $dir,
+ 'type' => 'd',
+ );
+ }
- }else{
-
- $opts = array(
- 'depth' => 1,
- 'listfiles' => true,
- 'listdirs' => true,
- 'pagesonly' => true,
- 'firsthead' => true,
- 'sneakyacl' => $conf['sneaky_index'],
- );
- if($id) $opts['filematch'] = '^.*\/'.$id;
- if($id) $opts['dirmatch'] = '^.*\/'.$id;
- search($data,$conf['datadir'],'search_universal',$opts,$nsd);
-
- // add back to upper
- if($ns){
- array_unshift($data,array(
- 'id' => getNS($ns),
- 'type' => 'u',
- ));
- }
- }
+ }else{
- // fixme sort results in a useful way ?
+ $opts = array(
+ 'depth' => 1,
+ 'listfiles' => true,
+ 'listdirs' => true,
+ 'pagesonly' => true,
+ 'firsthead' => true,
+ 'sneakyacl' => $conf['sneaky_index'],
+ );
+ if($id) $opts['filematch'] = '^.*\/'.$id;
+ if($id) $opts['dirmatch'] = '^.*\/'.$id;
+ search($data,$conf['datadir'],'search_universal',$opts,$nsd);
+
+ // add back to upper
+ if($ns){
+ array_unshift($data,array(
+ 'id' => getNS($ns),
+ 'type' => 'u',
+ ));
+ }
+ }
- if(!count($data)){
- echo $lang['nothingfound'];
- exit;
- }
+ // fixme sort results in a useful way ?
- // output the found data
- $even = 1;
- foreach($data as $item){
- $even *= -1; //zebra
+ if(!count($data)){
+ echo $lang['nothingfound'];
+ exit;
+ }
- if(($item['type'] == 'd' || $item['type'] == 'u') && $item['id']) $item['id'] .= ':';
- $link = wl($item['id']);
+ // output the found data
+ $even = 1;
+ foreach($data as $item){
+ $even *= -1; //zebra
- echo '<div class="'.(($even > 0)?'even':'odd').' type_'.$item['type'].'">';
+ if(($item['type'] == 'd' || $item['type'] == 'u') && $item['id']) $item['id'] .= ':';
+ $link = wl($item['id']);
+ echo '<div class="'.(($even > 0)?'even':'odd').' type_'.$item['type'].'">';
- if($item['type'] == 'u'){
- $name = $lang['upperns'];
- }else{
- $name = htmlspecialchars($item['id']);
- }
+ if($item['type'] == 'u'){
+ $name = $lang['upperns'];
+ }else{
+ $name = htmlspecialchars($item['id']);
+ }
- echo '<a href="'.$link.'" title="'.htmlspecialchars($item['id']).'" class="wikilink1">'.$name.'</a>';
+ echo '<a href="'.$link.'" title="'.htmlspecialchars($item['id']).'" class="wikilink1">'.$name.'</a>';
- if($item['title']){
- echo '<span>'.htmlspecialchars($item['title']).'</span>';
+ if($item['title']){
+ echo '<span>'.htmlspecialchars($item['title']).'</span>';
+ }
+ echo '</div>';
}
- echo '</div>';
- }
}
-//Setup VIM: ex: et ts=2 enc=utf-8 :
+//Setup VIM: ex: et ts=2 :
diff --git a/lib/exe/css.php b/lib/exe/css.php
index 76f40c7bb..4db81de0b 100644
--- a/lib/exe/css.php
+++ b/lib/exe/css.php
@@ -122,6 +122,9 @@ function css_out(){
// apply style replacements
$css = css_applystyle($css,$tplinc);
+
+ // place all @import statements at the top of the file
+ $css = css_moveimports($css);
// compress whitespace and comments
if($conf['compress']){
@@ -264,7 +267,8 @@ function css_loadfile($file,$location=''){
$css = io_readFile($file);
if(!$location) return $css;
- $css = preg_replace('#(url\([ \'"]*)((?!/|http://|https://| |\'|"))#','\\1'.$location.'\\3',$css);
+ $css = preg_replace('#(url\([ \'"]*)(?!/|http://|https://| |\'|")#','\\1'.$location,$css);
+ $css = preg_replace('#(@import\s+[\'"])(?!/|http://|https://)#', '\\1'.$location, $css);
return $css;
}
@@ -297,6 +301,29 @@ function css_pluginstyles($mode='screen'){
}
/**
+ * Move all @import statements in a combined stylesheet to the top so they
+ * aren't ignored by the browser.
+ *
+ * @author Gabriel Birke <birke@d-scribe.de>
+ */
+function css_moveimports($css)
+{
+ if(!preg_match_all('/@import\s+(?:url\([^)]+\)|"[^"]+")\s*[^;]*;\s*/', $css, $matches, PREG_OFFSET_CAPTURE)) {
+ return $css;
+ }
+ $newCss = "";
+ $imports = "";
+ $offset = 0;
+ foreach($matches[0] as $match) {
+ $newCss .= substr($css, $offset, $match[1] - $offset);
+ $imports .= $match[0];
+ $offset = $match[1] + strlen($match[0]);
+ }
+ $newCss .= substr($css, $offset);
+ return $imports.$newCss;
+}
+
+/**
* Very simple CSS optimizer
*
* @author Andreas Gohr <andi@splitbrain.org>
@@ -330,4 +357,4 @@ function css_comment_cb($matches){
return $matches[0];
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/exe/fetch.php b/lib/exe/fetch.php
index 680fd9ae4..3ad4f1937 100644
--- a/lib/exe/fetch.php
+++ b/lib/exe/fetch.php
@@ -198,4 +198,4 @@ function calc_cache($cache){
return -1; //cache endless
}
-//Setup VIM: ex: et ts=2 enc=utf-8 :
+//Setup VIM: ex: et ts=2 :
diff --git a/lib/exe/indexer.php b/lib/exe/indexer.php
index a5a7d6b2a..95e2af05b 100644
--- a/lib/exe/indexer.php
+++ b/lib/exe/indexer.php
@@ -31,7 +31,6 @@ $tmp = array(); // No event data
$evt = new Doku_Event('INDEXER_TASKS_RUN', $tmp);
if ($evt->advise_before()) {
runIndexer() or
- metaUpdate() or
runSitemapper() or
sendDigest() or
runTrimRecentChanges() or
@@ -139,51 +138,6 @@ function runIndexer(){
}
/**
- * Will render the metadata for the page if not exists yet
- *
- * This makes sure pages which are created from outside DokuWiki will
- * gain their data when viewed for the first time.
- */
-function metaUpdate(){
- global $ID;
- print "metaUpdate(): started".NL;
-
- if(!$ID) return false;
- $file = metaFN($ID, '.meta');
- echo "meta file: $file".NL;
-
- // rendering needed?
- if (@file_exists($file)) return false;
- if (!page_exists($ID)) return false;
-
- global $conf;
-
- // gather some additional info from changelog
- $info = io_grep($conf['changelog'],
- '/^(\d+)\t(\d+\.\d+\.\d+\.\d+)\t'.preg_quote($ID,'/').'\t([^\t]+)\t([^\t\n]+)/',
- 0,true);
-
- $meta = array();
- if(!empty($info)){
- $meta['date']['created'] = $info[0][1];
- foreach($info as $item){
- if($item[4] != '*'){
- $meta['date']['modified'] = $item[1];
- if($item[3]){
- $meta['contributor'][$item[3]] = $item[3];
- }
- }
- }
- }
-
- $meta = p_render_metadata($ID, $meta);
- p_save_metadata($ID, $meta);
-
- echo "metaUpdate(): finished".NL;
- return true;
-}
-
-/**
* Builds a Google Sitemap of all public pages known to the indexer
*
* The map is placed in the root directory named sitemap.xml.gz - This
@@ -312,6 +266,6 @@ function sendGIF(){
// Thinks it's got the whole image
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
// No trailing PHP closing tag - no output please!
// See Note at http://www.php.net/manual/en/language.basic-syntax.instruction-separation.php
diff --git a/lib/exe/js.php b/lib/exe/js.php
index f9682e1e9..117021308 100644
--- a/lib/exe/js.php
+++ b/lib/exe/js.php
@@ -396,4 +396,4 @@ function js_compress($s){
return trim($result);
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/exe/opensearch.php b/lib/exe/opensearch.php
index f16b4f681..03a1632c4 100644
--- a/lib/exe/opensearch.php
+++ b/lib/exe/opensearch.php
@@ -35,4 +35,4 @@ echo ' <Url type="application/x-suggestions+json" template="'.
DOKU_URL.'lib/exe/ajax.php?call=suggestions&amp;q={searchTerms}" />'.NL;
echo '</OpenSearchDescription>'.NL;
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/exe/xmlrpc.php b/lib/exe/xmlrpc.php
index 84068f96e..3d275cb2b 100644
--- a/lib/exe/xmlrpc.php
+++ b/lib/exe/xmlrpc.php
@@ -7,7 +7,7 @@ if(isset($HTTP_RAW_POST_DATA)) $HTTP_RAW_POST_DATA = trim($HTTP_RAW_POST_DATA);
/**
* Increased whenever the API is changed
*/
-define('DOKU_XMLRPC_API_VERSION',4);
+define('DOKU_XMLRPC_API_VERSION',5);
require_once(DOKU_INC.'inc/init.php');
session_write_close(); //close session
@@ -143,6 +143,13 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
true
);
+ $this->addCallback(
+ 'dokuwiki.appendPage',
+ 'this:appendPage',
+ array('int', 'string', 'string', 'struct'),
+ 'Append text to a wiki page.'
+ );
+
/* Wiki API v2 http://www.jspwiki.org/wiki/WikiRPCInterface2 */
$this->addCallback(
'wiki.getRPCVersionSupported',
@@ -289,6 +296,7 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* Return a raw wiki page
*/
function rawPage($id,$rev=''){
+ $id = cleanID($id);
if(auth_quickaclcheck($id) < AUTH_READ){
return new IXR_Error(1, 'You are not allowed to read this page');
}
@@ -344,6 +352,7 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* Return a wiki page rendered to html
*/
function htmlPage($id,$rev=''){
+ $id = cleanID($id);
if(auth_quickaclcheck($id) < AUTH_READ){
return new IXR_Error(1, 'You are not allowed to read this page');
}
@@ -480,6 +489,7 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* Return some basic data about a page
*/
function pageInfo($id,$rev=''){
+ $id = cleanID($id);
if(auth_quickaclcheck($id) < AUTH_READ){
return new IXR_Error(1, 'You are not allowed to read this page');
}
@@ -557,11 +567,23 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
}
/**
+ * Appends text to a wiki page.
+ */
+ function appendPage($id, $text, $params) {
+ $currentpage = $this->rawPage($id);
+ if (!is_string($currentpage)) {
+ return $currentpage;
+ }
+ return $this->putPage($id, $currentpage.$text, $params);
+ }
+
+ /**
* Uploads a file to the wiki.
*
* Michael Klier <chi@chimeric.de>
*/
function putAttachment($id, $file, $params) {
+ $id = cleanID($id);
global $conf;
global $lang;
@@ -629,6 +651,7 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* @author Gina Haeussge <osd@foosel.net>
*/
function deleteAttachment($id){
+ $id = cleanID($id);
$auth = auth_quickaclcheck(getNS($id).':*');
if($auth < AUTH_DELETE) return new IXR_ERROR(1, "You don't have permissions to delete files.");
global $conf;
@@ -686,6 +709,7 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* Returns the permissions of a given wiki page
*/
function aclCheck($id) {
+ $id = cleanID($id);
return auth_quickaclcheck($id);
}
@@ -695,13 +719,14 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* @author Michael Klier <chi@chimeric.de>
*/
function listLinks($id) {
+ $id = cleanID($id);
if(auth_quickaclcheck($id) < AUTH_READ){
return new IXR_Error(1, 'You are not allowed to read this page');
}
$links = array();
// resolve page instructions
- $ins = p_cached_instructions(wikiFN(cleanID($id)));
+ $ins = p_cached_instructions(wikiFN($id));
// instantiate new Renderer - needed for interwiki links
include(DOKU_INC.'inc/parser/xhtml.php');
@@ -809,6 +834,10 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
* @author Michael Klier <chi@chimeric.de>
*/
function pageVersions($id, $first) {
+ $id = cleanID($id);
+ if(auth_quickaclcheck($id) < AUTH_READ){
+ return new IXR_Error(1, 'You are not allowed to read this page');
+ }
global $conf;
$versions = array();
@@ -884,7 +913,8 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
$unlockfail = array();
foreach((array) $set['lock'] as $id){
- if(checklock($id)){
+ $id = cleanID($id);
+ if(auth_quickaclcheck($id) < AUTH_EDIT || checklock($id)){
$lockfail[] = $id;
}else{
lock($id);
@@ -893,10 +923,11 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
}
foreach((array) $set['unlock'] as $id){
- if(unlock($id)){
- $unlocked[] = $id;
- }else{
+ $id = cleanID($id);
+ if(auth_quickaclcheck($id) < AUTH_EDIT || !unlock($id)){
$unlockfail[] = $id;
+ }else{
+ $unlocked[] = $id;
}
}
@@ -929,4 +960,4 @@ class dokuwiki_xmlrpc_server extends IXR_IntrospectionServer {
$server = new dokuwiki_xmlrpc_server();
-// vim:ts=4:sw=4:et:enc=utf-8:
+// vim:ts=4:sw=4:et:
diff --git a/lib/images/interwiki/paypal.gif b/lib/images/interwiki/paypal.gif
new file mode 100644
index 000000000..4a063b4a5
--- /dev/null
+++ b/lib/images/interwiki/paypal.gif
Binary files differ
diff --git a/lib/images/interwiki/sb.gif b/lib/images/interwiki/sb.gif
index e272a29b7..8771b346d 100644
--- a/lib/images/interwiki/sb.gif
+++ b/lib/images/interwiki/sb.gif
Binary files differ
diff --git a/lib/plugins/acl/admin.php b/lib/plugins/acl/admin.php
index 84932f7ac..3e7bd8121 100644
--- a/lib/plugins/acl/admin.php
+++ b/lib/plugins/acl/admin.php
@@ -765,7 +765,7 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin {
//build code
$ret .= '<label for="pbox'.$label.'" title="'.$this->getLang('acl_perm'.$perm).'"'.$class.'>';
- $ret .= '<input '.html_attbuild($atts).' />&nbsp;';
+ $ret .= '<input '.buildAttributes($atts).' />&nbsp;';
$ret .= $this->getLang('acl_perm'.$perm);
$ret .= '</label>'.NL;
}
diff --git a/lib/plugins/acl/lang/de-informal/lang.php b/lib/plugins/acl/lang/de-informal/lang.php
index fdb6f5a89..e24584a55 100644
--- a/lib/plugins/acl/lang/de-informal/lang.php
+++ b/lib/plugins/acl/lang/de-informal/lang.php
@@ -6,6 +6,7 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['admin_acl'] = 'Zugriffskontrollsystem Management';
$lang['acl_group'] = 'Gruppe';
diff --git a/lib/plugins/acl/lang/de/lang.php b/lib/plugins/acl/lang/de/lang.php
index 0d30fe7a1..3c6bf8cf0 100644
--- a/lib/plugins/acl/lang/de/lang.php
+++ b/lib/plugins/acl/lang/de/lang.php
@@ -17,6 +17,8 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['admin_acl'] = 'Zugangsverwaltung';
$lang['acl_group'] = 'Gruppe';
diff --git a/lib/plugins/acl/lang/en/lang.php b/lib/plugins/acl/lang/en/lang.php
index 38ff20c88..779614d32 100644
--- a/lib/plugins/acl/lang/en/lang.php
+++ b/lib/plugins/acl/lang/en/lang.php
@@ -43,4 +43,4 @@ $lang['acl_perm8'] = 'Upload';
$lang['acl_perm16'] = 'Delete';
$lang['acl_new'] = 'Add new Entry';
$lang['acl_mod'] = 'Modify Entry';
-//Setup VIM: ex: et ts=2 enc=utf-8 :
+//Setup VIM: ex: et ts=2 :
diff --git a/lib/plugins/acl/lang/et/lang.php b/lib/plugins/acl/lang/et/lang.php
index e90d5eaa9..2f7208b7c 100644
--- a/lib/plugins/acl/lang/et/lang.php
+++ b/lib/plugins/acl/lang/et/lang.php
@@ -20,4 +20,4 @@ $lang['acl_perm2'] = 'Toimetamine';
$lang['acl_perm4'] = 'Tekitamine';
$lang['acl_perm8'] = 'Üles laadimine';
$lang['acl_new'] = 'Uue kirje lisamine';
-//Setup VIM: ex: et ts=2 enc=utf-8 :
+//Setup VIM: ex: et ts=2 :
diff --git a/lib/plugins/acl/lang/he/lang.php b/lib/plugins/acl/lang/he/lang.php
index ac00730dd..91025f4b8 100644
--- a/lib/plugins/acl/lang/he/lang.php
+++ b/lib/plugins/acl/lang/he/lang.php
@@ -7,6 +7,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['admin_acl'] = 'ניהול רשימת בקרת גישות';
$lang['acl_group'] = 'קבוצה';
diff --git a/lib/plugins/acl/lang/ko/lang.php b/lib/plugins/acl/lang/ko/lang.php
index 43a5ceeeb..6f4e991cb 100644
--- a/lib/plugins/acl/lang/ko/lang.php
+++ b/lib/plugins/acl/lang/ko/lang.php
@@ -10,6 +10,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['admin_acl'] = '접근 제어 목록 관리';
$lang['acl_group'] = '그룹';
diff --git a/lib/plugins/acl/lang/la/help.txt b/lib/plugins/acl/lang/la/help.txt
index ba974f48c..553884c30 100644
--- a/lib/plugins/acl/lang/la/help.txt
+++ b/lib/plugins/acl/lang/la/help.txt
@@ -1,8 +1,8 @@
=== Auxilium: ===
-Hic facultates spatiorum nominis paginarumque addere delereue potes.
+Hic facultates generum paginarumque addere delereue potes.
-Tabella sinistra omnes paginas spatia nominisque ostendit.
+Tabella sinistra omnes paginas generaque ostendit.
His campis mutare facultates electorum Sodalium Gregumque potes.
diff --git a/lib/plugins/acl/lang/la/lang.php b/lib/plugins/acl/lang/la/lang.php
index dd6043602..941de1f79 100644
--- a/lib/plugins/acl/lang/la/lang.php
+++ b/lib/plugins/acl/lang/la/lang.php
@@ -2,25 +2,26 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
-$lang['admin_acl'] = 'Aditus Administrationis Aditus';
+$lang['admin_acl'] = 'Administratio Indicis Custodiae Aditus';
$lang['acl_group'] = 'Grex';
$lang['acl_user'] = 'Sodalis';
$lang['acl_perms'] = 'Facultas:';
$lang['page'] = 'Pagina';
-$lang['namespace'] = 'Spatium nominis';
+$lang['namespace'] = 'Genus';
$lang['btn_select'] = 'eligere';
$lang['p_user_id'] = 'Sodalis <b class="acluser">%s</b> nunc has facultates paginae "<b class="aclpage">%s</b> habes: <i>%s</i>.';
-$lang['p_user_ns'] = 'Sodalis <b class="acluser">%s</b> nunc has facultates spatio nominis "<b class="aclns">%s</b> habes: <i>%s</i>.';
+$lang['p_user_ns'] = 'Sodalis <b class="acluser">%s</b> nunc has facultates generis "<b class="aclns">%s</b> habes: <i>%s</i>.';
$lang['p_group_id'] = 'Socius\a gregis <b class="aclgroup">%s</b> nunc has facultates paginae "<b class="aclpage">%s</b> habes: <i>%s</i>.';
-$lang['p_group_ns'] = 'Socius\a gregis <b class="aclgroup">%s</b> nunc has facultates paginae "<b class="aclns">%s</b> habes: <i>%s</i>.';
+$lang['p_group_ns'] = 'Socius\a gregis <b class="aclgroup">%s</b> nunc has facultates generis "<b class="aclns">%s</b> habes: <i>%s</i>.';
$lang['p_choose_id'] = '<b>Sodalis grexue</b> in campo insere ut facultates paginae <b class="aclpage">%s</b> uideas.';
-$lang['p_choose_ns'] = '<b>Sodalis grexue</b> in campo insere ut facultates paginae <b class="aclns">%s</b> uideas.';
-$lang['p_inherited'] = 'Caue: hae facultates et huic rei et aliis gregibus uel spatiis nominis legitimae sunt.';
+$lang['p_choose_ns'] = '<b>Sodalis grexue</b> in campo insere ut facultates generis <b class="aclns">%s</b> uideas.';
+$lang['p_inherited'] = 'Caue: hae facultates et huic rei et aliis gregibus uel generibus legitimae sunt.';
$lang['p_isadmin'] = 'Caue: electi greges semper plenum ius habent, eo quod ut magister\stra elegitur.';
-$lang['p_include'] = 'Maiores facultates minores includunt. Creare, onerare uel delere facultates solum spatis nominis, non paginis potes';
-$lang['current'] = 'Communes AAA leges';
-$lang['where'] = 'Pagina/Spatium nominis';
+$lang['p_include'] = 'Maiores facultates minores includunt. Creandi, onerandi uel delendi facultates solum generibus, non paginis sunt.';
+$lang['current'] = 'Communes ICA leges';
+$lang['where'] = 'Pagina/Genus';
$lang['who'] = 'Sodalis/Grex';
$lang['perm'] = 'Facultates';
$lang['acl_perm0'] = 'Nihil';
diff --git a/lib/plugins/acl/lang/ru/help.txt b/lib/plugins/acl/lang/ru/help.txt
index a3c1b4f64..7807105a8 100644
--- a/lib/plugins/acl/lang/ru/help.txt
+++ b/lib/plugins/acl/lang/ru/help.txt
@@ -1,11 +1,7 @@
-=== Краткая справка: ===
+=== Краткая справка ===
-На этой странице вы можете добавить или удалить права доступа к пространствам имён и страницам вашей вики.
-
-На панели слева отображены доступные пространства имён и страницы.
-
-Форма выше позволяет вам просмотреть и изменить права доступа для выбранного пользователя или группы.
-
-Текущие права доступа отображены в таблице ниже. Вы можете использовать её для быстрого удаления или изменения правил.
-
-Прочтение [[doku>acl|официальной документации по ACL]] может помочь вам в полном понимании работы управления правами доступа в «ДокуВики».
+На этой странице вы можете добавить или удалить права доступа к пространствам имён и страницам своей вики.\\
+На панели слева отображены доступные пространства имён и страницы.\\
+Форма выше позволяет вам просмотреть и изменить права доступа для выбранного пользователя или группы.\\
+Текущие права доступа отображены в таблице ниже. Вы можете использовать её для быстрого удаления или изменения правил.\\
+Прочтение [[doku>acl|официальной документации по ACL]] может помочь вам в полном понимании работы управления правами доступа в «ДокуВики».
diff --git a/lib/plugins/acl/lang/ru/lang.php b/lib/plugins/acl/lang/ru/lang.php
index 0c02dfbb1..f49e4b55a 100644
--- a/lib/plugins/acl/lang/ru/lang.php
+++ b/lib/plugins/acl/lang/ru/lang.php
@@ -19,7 +19,7 @@ $lang['acl_group'] = 'Группа';
$lang['acl_user'] = 'Пользователь';
$lang['acl_perms'] = 'Права доступа для';
$lang['page'] = 'Страница';
-$lang['namespace'] = 'Пространство имен';
+$lang['namespace'] = 'Пространство имён';
$lang['btn_select'] = 'Выбрать';
$lang['p_user_id'] = 'Сейчас пользователь <b class="acluser">%s</b> имеет следующие права на доступ к странице <b class="aclpage">%s</b>: <i>%s</i>.';
$lang['p_user_ns'] = 'Сейчас пользователь <b class="acluser">%s</b> имеет следующие права на доступ к пространству имён <b class="aclns">%s</b>: <i>%s</i>.';
diff --git a/lib/plugins/acl/lang/sl/lang.php b/lib/plugins/acl/lang/sl/lang.php
index 32141fbce..f6dec25ef 100644
--- a/lib/plugins/acl/lang/sl/lang.php
+++ b/lib/plugins/acl/lang/sl/lang.php
@@ -4,14 +4,29 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
+$lang['admin_acl'] = 'ACL administracija';
$lang['acl_group'] = 'Skupina';
$lang['acl_user'] = 'Uporabnik';
$lang['acl_perms'] = 'Dovoljenja za';
$lang['page'] = 'Stran';
+$lang['namespace'] = 'Imenski prostor';
$lang['btn_select'] = 'Izberi';
+$lang['p_user_id'] = 'Uporabnik %s ima trenutno naslednje pravice na strani %s: %s.';
+$lang['p_user_ns'] = 'Uporabnik %s ima trenutno naslednje pravice v imenskem prostoru %s: %s.';
+$lang['p_group_id'] = 'Uporabnikka skupina %s ima trenutno naslednje pravice na strani %s: %s.';
+$lang['p_group_ns'] = 'Uporabniška skupina %s ima trenutno naslednje pravice v imenskem prostoru %s: %s.';
+$lang['p_choose_id'] = 'Prosimo vnesite <b>uporabnika ali skupino</b> v zgornji obrazec za ogled ali urejanje pravic za stran %s.';
+$lang['p_choose_ns'] = 'Prosimo vnesite <b>uporabnika ali skupino</b> v zgornji obrazec za ogled ali urejanje pravic za imenski prostor %s.';
+$lang['p_inherited'] = 'Opomba: Te pravice niso bile posebej nastavljene, temveč prevzete iz drugih skupin ali višjih imenskih prostorov.';
+$lang['p_isadmin'] = 'Opomba: Izbrana skupina ali uporabnik imajo vedno vse pravice, ker so določeni kot superuporabniki.';
+$lang['p_include'] = 'Višje pravice vključujejo tudi nižje. ';
+$lang['current'] = 'Trenutna ACL pravila';
+$lang['where'] = 'Stran / Imenski prostor';
$lang['who'] = 'Uporabnik/Skupina';
$lang['perm'] = 'Dovoljenja';
+$lang['acl_perm0'] = 'Nič';
$lang['acl_perm1'] = 'Preberi';
$lang['acl_perm2'] = 'Uredi';
$lang['acl_perm4'] = 'Ustvari';
diff --git a/lib/plugins/acl/lang/tr/lang.php b/lib/plugins/acl/lang/tr/lang.php
index 45fbe7489..de96d2906 100644
--- a/lib/plugins/acl/lang/tr/lang.php
+++ b/lib/plugins/acl/lang/tr/lang.php
@@ -4,11 +4,10 @@
*
* @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
* @author Selim Farsakoğlu <farsakogluselim@yahoo.de>
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['admin_acl'] = 'Erişim Kontrol Listesi (ACL) Yönetimi';
$lang['acl_group'] = 'Grup';
diff --git a/lib/plugins/acl/lang/vi/lang.php b/lib/plugins/acl/lang/vi/lang.php
index 4458d806b..6237f79ba 100644
--- a/lib/plugins/acl/lang/vi/lang.php
+++ b/lib/plugins/acl/lang/vi/lang.php
@@ -18,4 +18,4 @@ $lang['acl_perm2'] = 'Biên soạn';
$lang['acl_perm4'] = 'Tạo';
$lang['acl_perm8'] = 'Tải lên';
$lang['acl_new'] = 'Thêm mục mới';
-//Setup VIM: ex: et ts=2 enc=utf-8 :
+//Setup VIM: ex: et ts=2 :
diff --git a/lib/plugins/admin.php b/lib/plugins/admin.php
index 25f01b657..9a1fb9fdc 100644
--- a/lib/plugins/admin.php
+++ b/lib/plugins/admin.php
@@ -43,4 +43,4 @@ class DokuWiki_Admin_Plugin extends DokuWiki_Plugin {
return array();
}
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/config/lang/ar/lang.php b/lib/plugins/config/lang/ar/lang.php
index 5d0ff76b9..26cc16e5c 100644
--- a/lib/plugins/config/lang/ar/lang.php
+++ b/lib/plugins/config/lang/ar/lang.php
@@ -116,6 +116,7 @@ $lang['rss_update'] = 'تحديث تلقيم XML (ثوان)';
$lang['recent_days'] = 'مدة إبقاء أحدث التغييرات (ايام)';
$lang['rss_show_summary'] = 'تلقيم XML يظهر ملخصا في العنوان';
$lang['target____wiki'] = 'النافذة الهدف للروابط الداخلية';
+$lang['target____interwiki'] = 'النافذة الهدف للروابط الممرة interwiki';
$lang['target____extern'] = 'النافذة الهدف للروابط الخارجية';
$lang['target____media'] = 'النافذة الهدف لروابط الوسائط';
$lang['target____windows'] = 'النافذة الهدف لروابط النوافذ';
@@ -124,6 +125,7 @@ $lang['proxy____port'] = 'منفذ الوكيل';
$lang['proxy____user'] = 'اسم مستخدم الوكيل';
$lang['proxy____pass'] = 'كلمة سر الوكيل';
$lang['proxy____ssl'] = 'استخدم ssl للاتصال بالوكيل';
+$lang['proxy____except'] = 'تعبير شرطي لمقابلة العناوين التي ستتجاوز البروكسي.';
$lang['safemodehack'] = 'مكّن hack الوضع الآمن';
$lang['ftp____host'] = 'خادوم FTP ل hack الوضع الآمن';
$lang['ftp____port'] = 'منفذ FTP ل hack الوضع الآمن';
@@ -136,6 +138,7 @@ $lang['typography_o_1'] = 'استبعاد الاقتباس المفرد';
$lang['typography_o_2'] = 'تضمين علامات اقتباس مفردة (قد لا يعمل دائما)';
$lang['userewrite_o_0'] = 'لاشيء';
$lang['userewrite_o_1'] = '.htaccess';
+$lang['userewrite_o_2'] = 'دو';
$lang['deaccent_o_0'] = 'معطل';
$lang['gdlib_o_0'] = 'مكتبة GD غير متوفرة';
$lang['gdlib_o_1'] = 'الاصدار 1.x';
@@ -156,11 +159,15 @@ $lang['compression_o_0'] = 'لا شيء';
$lang['compression_o_gz'] = 'gzip';
$lang['compression_o_bz2'] = 'bz2';
$lang['xsendfile_o_0'] = 'لا تستخدم';
+$lang['xsendfile_o_1'] = 'ترويسة lighttpd مملوكة (قبل الاصدار 1.5)';
+$lang['xsendfile_o_2'] = 'ترويسة X-Sendfile قياسية';
+$lang['xsendfile_o_3'] = 'ترويسة Nginx X-Accel-Redirect مملوكة';
$lang['showuseras_o_loginname'] = 'اسم الدخول';
$lang['showuseras_o_username'] = 'اسم المستخدم الكامل';
$lang['showuseras_o_email'] = 'عنوان بريد المستخدم (مبهم تبعا لاعدادات حارس_البريد)';
$lang['showuseras_o_email_link'] = 'عنوان بريد المستخدم كـ مالتيو: رابط';
$lang['useheading_o_0'] = 'أبدا';
-$lang['useheading_o_navigation'] = 'ال';
+$lang['useheading_o_navigation'] = 'التنقل فقط';
$lang['useheading_o_content'] = 'محتوى الويكي فقط';
$lang['useheading_o_1'] = 'دائما';
+$lang['readdircache'] = 'المدة القصوى لتخزين ';
diff --git a/lib/plugins/config/lang/cs/intro.txt b/lib/plugins/config/lang/cs/intro.txt
index bad92ac8e..63381b84e 100644
--- a/lib/plugins/config/lang/cs/intro.txt
+++ b/lib/plugins/config/lang/cs/intro.txt
@@ -2,7 +2,7 @@
Tuto stránku můžete používat ke správě nastavení vaší instalace DokuWiki. Nápovědu pro konkrétní položky nastavení naleznete na [[doku>config]]. Pro další detaily o tomto pluginu viz [[doku>plugin:config]].
-Položky se světle červeným pozadím jsou chráněné a nelze je upravovat tímto pluginem. Položky s modrým pozadím jsou výchozí hodnoty a položky s bílým pozadím byly nastaveny lokálně v této konktétní instalaci. Modré i bílé položky je možné upravovat.
+Položky se světle červeným pozadím jsou chráněné a nelze je upravovat tímto pluginem. Položky s modrým pozadím jsou výchozí hodnoty a položky s bílým pozadím byly nastaveny lokálně v této konkrétní instalaci. Modré i bílé položky je možné upravovat.
Než opustíte tuto stránku, nezapomeňte stisknout tlačítko **Uložit**, jinak budou změny ztraceny.
diff --git a/lib/plugins/config/lang/cs/lang.php b/lib/plugins/config/lang/cs/lang.php
index 3f8c05f26..06839c1d0 100644
--- a/lib/plugins/config/lang/cs/lang.php
+++ b/lib/plugins/config/lang/cs/lang.php
@@ -11,7 +11,7 @@
*/
$lang['menu'] = 'Správa nastavení';
$lang['error'] = 'Nastavení nebyla změněna kvůli alespoň jedné neplatné položce,
-zkotrolujte prosím své úpravy a odešlete je znovu.<br />
+zkontrolujte prosím své úpravy a odešlete je znovu.<br />
Neplatné hodnoty se zobrazí v červeném rámečku.';
$lang['updated'] = 'Nastavení byla úspěšně upravena.';
$lang['nochoice'] = '(nejsou k dispozici žádné další volby)';
@@ -69,10 +69,10 @@ $lang['useheading'] = 'Používat první nadpis jako název stránky'
$lang['refcheck'] = 'Kontrolovat odkazy na média (před vymazáním)';
$lang['refshow'] = 'Počet zobrazených odkazů na média';
$lang['allowdebug'] = 'Povolit debugování. <b>Vypněte, pokud to nepotřebujete!</b>';
-$lang['usewordblock'] = 'Blokovat spam za použítí seznamu známých spamových slov';
+$lang['usewordblock'] = 'Blokovat spam za použití seznamu známých spamových slov';
$lang['indexdelay'] = 'Časová prodleva před indexací (v sekundách)';
$lang['relnofollow'] = 'Používat rel="nofollow" na externí odkazy';
-$lang['mailguard'] = 'Metoda "zamaskování" emailových addres';
+$lang['mailguard'] = 'Metoda "zamaskování" emailových adres';
$lang['iexssprotect'] = 'Zkontrolovat nahrané soubory vůči možnému škodlivému JavaScriptu či HTML';
$lang['showuseras'] = 'Co se má přesně zobrazit, když se ukazuje uživatel, který naposledy editoval stránku';
$lang['useacl'] = 'Používat přístupová práva (ACL)';
@@ -95,7 +95,7 @@ vnořené jmenné prostory, k nimž právo má, budou přesto skryty.
To může mít za následek, že index bude při některých
nastaveních ACL nepoužitelný.';
$lang['auth_security_timeout'] = 'Časový limit pro autentikaci (v sekundách)';
-$lang['securecookie'] = 'Má prohlížeč posílat cookies nastavené přes HTTPS opět jen přes HTTPS? Vypňete tuto volbu, pokud chcete, aby bylo pomocí SSL zabezpečeno pouze přihlašování do wiki, ale obsah budete prohlížet nezabezpečeně.';
+$lang['securecookie'] = 'Má prohlížeč posílat cookies nastavené přes HTTPS opět jen přes HTTPS? Vypněte tuto volbu, pokud chcete, aby bylo pomocí SSL zabezpečeno pouze přihlašování do wiki, ale obsah budete prohlížet nezabezpečeně.';
$lang['xmlrpc'] = 'Povolit/Zakázat rozhraní XML-RPC.';
$lang['xmlrpcuser'] = 'Omezit přístup pomocí XML-RPC pouze na zde zadané skupiny či uživatele (oddělené čárkami). Necháte-li pole prázdné, dáte přístup komukoliv.';
$lang['updatecheck'] = 'Kontrolovat aktualizace a bezpečnostní varování? DokuWiki potřebuje pro tuto funkci přístup k splitbrain.org';
@@ -112,7 +112,7 @@ $lang['locktime'] = 'Maximální životnost zámkových souborů (v
$lang['fetchsize'] = 'Maximální velikost souboru (v bajtech), co ještě fetch.php bude stahovat z externích zdrojů';
$lang['notify'] = 'Posílat oznámení o změnách na následující emailovou adresu';
$lang['registernotify'] = 'Posílat informace o nově registrovaných uživatelích na tuto mailovou adresu';
-$lang['mailfrom'] = 'Emailová addresa, která se bude používat pro automatické maily';
+$lang['mailfrom'] = 'Emailová adresa, která se bude používat pro automatické maily';
$lang['gzip_output'] = 'Používat pro xhtml Content-Encoding gzip';
$lang['gdlib'] = 'Verze GD knihovny';
$lang['im_convert'] = 'Cesta k nástroji convert z balíku ImageMagick';
diff --git a/lib/plugins/config/lang/de-informal/lang.php b/lib/plugins/config/lang/de-informal/lang.php
index 01beeeeb9..f6ddaa8e9 100644
--- a/lib/plugins/config/lang/de-informal/lang.php
+++ b/lib/plugins/config/lang/de-informal/lang.php
@@ -6,6 +6,7 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Einstellungen';
$lang['error'] = 'Einstellungen wurden nicht aktualisiert auf Grund eines ungültigen Wertes. Bitte überprüfe deine Änderungen und versuche es erneut.<br />Die/der ungültige(n) Wert(e) werden durch eine rote Umrandung hervorgehoben.';
@@ -102,6 +103,7 @@ $lang['fetchsize'] = 'Maximale Größe (in Bytes), die fetch.php von
$lang['notify'] = 'Sende Änderungsbenachrichtigungen an diese E-Mail-Adresse.';
$lang['registernotify'] = 'Sende Information bei neu registrierten Benutzern an diese E-Mail-Adresse.';
$lang['mailfrom'] = 'Absenderadresse für automatisch erzeugte E-Mails';
+$lang['mailprefix'] = 'Präfix für E-Mail-Betreff beim automatischen Versand von Benachrichtigungen';
$lang['gzip_output'] = 'Seiten mit gzip komprimiert ausliefern';
$lang['gdlib'] = 'GD Lib Version';
$lang['im_convert'] = 'Pfad zu ImageMagicks Konvertierwerkzeug';
diff --git a/lib/plugins/config/lang/de/lang.php b/lib/plugins/config/lang/de/lang.php
index aa763da03..b26df4993 100644
--- a/lib/plugins/config/lang/de/lang.php
+++ b/lib/plugins/config/lang/de/lang.php
@@ -13,6 +13,8 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Konfiguration';
$lang['error'] = 'Die Einstellungen wurden wegen einer fehlerhaften Eingabe nicht gespeichert.
@@ -111,6 +113,7 @@ $lang['fetchsize'] = 'Maximale Größe (in Bytes), die fetch.php von
$lang['notify'] = 'Änderungsmitteilungen an diese E-Mail-Adresse versenden';
$lang['registernotify'] = 'Information über neu registrierte Nutzer an diese E-Mail-Adresse senden';
$lang['mailfrom'] = 'Absender-E-Mail-Adresse für automatische Mails';
+$lang['mailprefix'] = 'Präfix für E-Mail-Betreff beim automatischen Versand von Benachrichtigungen';
$lang['gzip_output'] = 'Seiten mit gzip komprimiert ausliefern';
$lang['gdlib'] = 'GD Lib Version';
$lang['im_convert'] = 'Pfad zu ImageMagicks Konvertierwerkzeug';
diff --git a/lib/plugins/config/lang/en/lang.php b/lib/plugins/config/lang/en/lang.php
index 85214bf98..d7a544850 100644
--- a/lib/plugins/config/lang/en/lang.php
+++ b/lib/plugins/config/lang/en/lang.php
@@ -125,6 +125,7 @@ $lang['fetchsize'] = 'Maximum size (bytes) fetch.php may download from extern'
$lang['notify'] = 'Send change notifications to this email address';
$lang['registernotify'] = 'Send info on newly registered users to this email address';
$lang['mailfrom'] = 'Email address to use for automatic mails';
+$lang['mailprefix'] = 'Email subject prefix to use for automatic mails';
$lang['gzip_output'] = 'Use gzip Content-Encoding for xhtml';
$lang['gdlib'] = 'GD Lib version';
$lang['im_convert'] = 'Path to ImageMagick\'s convert tool';
diff --git a/lib/plugins/config/lang/he/lang.php b/lib/plugins/config/lang/he/lang.php
index a39d0ab5c..ab4a8928e 100644
--- a/lib/plugins/config/lang/he/lang.php
+++ b/lib/plugins/config/lang/he/lang.php
@@ -7,6 +7,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['menu'] = 'הגדרות תצורה';
$lang['error'] = 'ההגדרות לא עודכנו בגלל ערך לא תקף, נא לעיין בשינויים ולשלוח שנית.
diff --git a/lib/plugins/config/lang/ko/lang.php b/lib/plugins/config/lang/ko/lang.php
index efac643ab..13f5efefe 100644
--- a/lib/plugins/config/lang/ko/lang.php
+++ b/lib/plugins/config/lang/ko/lang.php
@@ -7,6 +7,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['menu'] = '환경 설정';
$lang['error'] = '잘못된 값때문에 설정들을 변경할 수 없습니다. 수정한 값들을 검사하고 확인을 누르기 바랍니다.
@@ -89,12 +90,15 @@ $lang['sneaky_index'] = '기본적으로, DokuWiki는 색인 목록에
특정 ACL 설정은 색인 사용이 불가능하게 할 수도 있습니다.';
$lang['auth_security_timeout'] = '인증 보안 초과 시간(초)';
$lang['securecookie'] = 'HTTPS로 보내진 쿠키는 HTTPS에만 적용 할까요? 위키의 로그인 페이지만 SSL로 암호화 하고 위키 페이지는 그렇지 않은경우 꺼야 합니다.';
+$lang['xmlrpc'] = 'XML-RPC 인터페이스 지원/무시';
+$lang['xmlrpcuser'] = '주어진 그룹이나 유저들에게만 XML-RPC접근을 허락하려면 컴마로 구분하여 적으세요. 비어두면 모두에게 허용됩니다.';
$lang['updatecheck'] = '업데이트와 보안 문제를 검사(DokuWiki를 splitbrain.org에 연결해야 합니다.)';
$lang['userewrite'] = 'URL rewriting기능 사용';
$lang['useslash'] = 'URL에서 네임스페이스 구분자로 슬래쉬 문자 사용';
$lang['usedraft'] = '편집하는 동안 자동으로 문서 초안 저장';
$lang['sepchar'] = '페이지 이름 단어 구분자';
$lang['canonical'] = '완전한 canonical URL 사용';
+$lang['fnencode'] = '아스키가 아닌 파일이르믈 인코딩 하는 방법.';
$lang['autoplural'] = '링크 연결시 plural폼 검사';
$lang['compression'] = 'attic파일 압축 방법 선택';
$lang['cachetime'] = '최대 캐쉬 생존 시간(초)';
@@ -108,6 +112,7 @@ $lang['gdlib'] = 'GD 라이브러리 버전';
$lang['im_convert'] = 'ImageMagick 위치';
$lang['jpg_quality'] = 'JPG 압축 품질 (0-100)';
$lang['subscribers'] = '페이지 갱신 알람 기능';
+$lang['subscribe_time'] = ' 구독 목록과 요약이 보내질 경과 시간 (초); 이 것은 recent_days에서 설정된 시간보다 작아야 합니다.';
$lang['compress'] = '최적화된 CSS, javascript 출력';
$lang['hidepages'] = '매칭된 페이지 숨기기(정규표현식)';
$lang['send404'] = '존재하지 않는 페이지에 대해 "HTTP 404/Page Not Found" 응답';
@@ -115,7 +120,6 @@ $lang['sitemap'] = '구글 사이트맵 생성(날짜)';
$lang['broken_iua'] = '설치된 시스템에서 ignore_user_abort 기능에 문제가 있으면 색인이 정상적으로 동작하지 않습니다. 이 기능이 IIS+PHP/CGI에서 문제가 있는 것으로 알려졌습니다. 자세한 정보는 <a href="http://bugs.splitbrain.org/?do=details&amp;task_id=852">Bug 852</a>를 참고하기 바랍니다.';
$lang['xsendfile'] = '웹 서버 static 파일 전송 지원을 위해 X-Sendfile 헤더를 사용한다면 이 옵션을 사용합니다.
웹 서버가 이 기능을 지원해야 합니다.';
-$lang['xmlrpc'] = 'XML-RPC 인터페이스 지원/무시';
$lang['renderer_xhtml'] = '주 (xhtml) 위키 출력 처리기';
$lang['renderer__core'] = '%s (DokuWiki 내부 기능)';
$lang['renderer__plugin'] = '%s (DokuWiki 플러그인)';
@@ -136,6 +140,7 @@ $lang['proxy____port'] = '프록시 서버 포트';
$lang['proxy____user'] = '프록시 사용자 이름';
$lang['proxy____pass'] = '프록시 패스워드';
$lang['proxy____ssl'] = '프록시 연결시 ssl사용';
+$lang['proxy____except'] = '프록시설정이 무시될 URL주소들의 RegEx형식표현';
$lang['safemodehack'] = 'safemode hack기능 사용';
$lang['ftp____host'] = 'safemode hack의 FTP 서버';
$lang['ftp____port'] = 'safemode hack의 FTP port';
@@ -183,3 +188,4 @@ $lang['useheading_o_0'] = '아니요';
$lang['useheading_o_navigation'] = '네비게이션에만';
$lang['useheading_o_content'] = '위키 내용에만';
$lang['useheading_o_1'] = '항상';
+$lang['readdircache'] = 'readdir 캐쉬를 위한 최대 시간 (초)';
diff --git a/lib/plugins/config/lang/la/intro.txt b/lib/plugins/config/lang/la/intro.txt
index d23029ab1..573d34ac1 100644
--- a/lib/plugins/config/lang/la/intro.txt
+++ b/lib/plugins/config/lang/la/intro.txt
@@ -1,6 +1,6 @@
-====== Administrationis Administrator ======
+====== Optionum Administratio ======
-In hac pagina administratoris optiones mutare et inspicere potes. Auxilia in pagina [[doku>config]] sunt, si singulas res uidere uis, i ad paginam [[doku>plugin:config]].
+In hac pagina administratoris optiones mutare et inspicere potes. Auxilia in pagina [[doku>config|conformationis]] sunt, si singulas res uidere uis, i ad paginam [[doku>plugin:config|conformationis]].
Optiones ostensae rubro colore tutae et non nunc mutabiles sunt. Optiones ostensae caeruleo colore praecipuae sunt et optiones ostensae in area alba singulares huic uici sunt. Et caerulae et albae optiones mutabiles sunt.
diff --git a/lib/plugins/config/lang/la/lang.php b/lib/plugins/config/lang/la/lang.php
index ca0eb1c31..689ea004d 100644
--- a/lib/plugins/config/lang/la/lang.php
+++ b/lib/plugins/config/lang/la/lang.php
@@ -2,6 +2,7 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
$lang['menu'] = 'Optiones Administrationis';
$lang['error'] = 'Optiones non nouatae ob errores: rursum temptat. Errores rubro colore signati sunt.';
@@ -9,17 +10,17 @@ $lang['updated'] = 'Optiones feliciter nouatae.';
$lang['nochoice'] = '(nulla optio est)';
$lang['locked'] = 'Optio documenti non nouata est, <br/> optiones et facultates documenti inspicis.';
$lang['danger'] = 'CAVE: si has optiones mutabis, in administrationis indicem non inire potes.';
-$lang['warning'] = 'CAVE: si hae optiones mutantur, graues errores erunt.';
-$lang['security'] = 'CAVE: si hae optiones mutantur, graues errores erunt.';
-$lang['_configuration_manager'] = 'Administrationis Administrator';
+$lang['warning'] = 'CAVE: si hae optiones mutabis, graues errores erunt.';
+$lang['security'] = 'CAVE: si hae optiones mutabis, graues errores erunt.';
+$lang['_configuration_manager'] = 'Optionum administratio';
$lang['_header_dokuwiki'] = 'Vicis Optiones';
$lang['_header_plugin'] = 'Addendorum Optiones';
$lang['_header_template'] = 'Vicis Formae Optiones';
$lang['_header_undefined'] = 'Variae Optiones';
-$lang['_basic'] = 'Fundamenti Optiones';
-$lang['_display'] = 'Visiuae Optiones';
+$lang['_basic'] = 'Praecipuae Optiones';
+$lang['_display'] = 'Speciei Optiones';
$lang['_authentication'] = 'Confirmationis Optiones';
-$lang['_anti_spam'] = 'Malorum Optiones';
+$lang['_anti_spam'] = 'In Mala Optiones';
$lang['_editing'] = 'Recensendi Optiones';
$lang['_links'] = 'Nexi Optiones';
$lang['_media'] = 'Visiuorum Optiones';
@@ -70,7 +71,7 @@ $lang['autopasswd'] = 'Tessera machinatione generata';
$lang['authtype'] = 'Confirmationis finis';
$lang['passcrypt'] = 'Ratio tesserae tuendae';
$lang['defaultgroup'] = 'Grex communis';
-$lang['superuser'] = 'Magister\stra - grex, Sodalis uel index diuisus a uigulis sodalis1,@grex,sodalis2 cum plenis facultatibus sine AAA optionum termino';
+$lang['superuser'] = 'Magister\stra - grex, Sodalis uel index diuisus a uigulis sodalis1,@grex,sodalis2 cum plenis facultatibus sine ICA optionum termino';
$lang['manager'] = 'Administrator - grex, Sodalis uel index diuisus a uigulis sodalis1,@grex,sodalis2 cum certis facultatibus';
$lang['profileconfirm'] = 'Mutationes tessera confirmanda sunt';
$lang['disableactions'] = 'Vicis actiones ineptas facere';
@@ -78,14 +79,14 @@ $lang['disableactions_check'] = 'Inspicere';
$lang['disableactions_subscription'] = 'Inscribe/Delere';
$lang['disableactions_wikicode'] = 'Fontem uidere/Rudem transcribere';
$lang['disableactions_other'] = 'Aliae actiones (uirgulis diuisae)';
-$lang['sneaky_index'] = 'Hic uicis omnes spatia nomini in indice inserit. Si ineptam hanc optionem facias, solum ea spatia, quae Sodales uidere possunt, in indice erunt. Hoc suggreges et subspatia abscondere potest.';
+$lang['sneaky_index'] = 'Hic uicis omnia genera in indice inserit. Si ineptam hanc optionem facias, solum ea, quae Sodales uidere possunt, in indice erunt. Hoc suggreges et suggenera abscondere potest.';
$lang['auth_security_timeout'] = 'Confirmationis Tempus (secundis)';
$lang['securecookie'] = 'Formulae HTTPS mittine solum per HTTPS possunt? Ineptam hanc optio facias, si accessus uicis tutus est, sed interretis non.';
$lang['xmlrpc'] = 'Aptam\Ineptam XML-RPC administrationem facere';
$lang['xmlrpcuser'] = 'Accessus XML-RPC gregibus uel Sodalibus in hoc indice astringere. Nihil scribere ut omnes accessum habeant';
$lang['updatecheck'] = 'Nouationes et fiducias inspicerene? Hic uicis connectere splitbrain.org debes.';
$lang['userewrite'] = 'VRL formosis uti';
-$lang['useslash'] = 'Repagula ut spatium nominis diuidas uti';
+$lang['useslash'] = 'Repagula in URL, ut genera diuidas, uti';
$lang['usedraft'] = 'Propositum in recensione machinatione seruatur';
$lang['sepchar'] = 'Signum, quod paginas diuidit';
$lang['canonical'] = 'VRL perfecto uti';
@@ -99,7 +100,7 @@ $lang['notify'] = 'Adnotationis mutationes ad hunc cursum mittere
$lang['registernotify'] = 'De nouis Sodalibus ad hunc cursum notas mittere';
$lang['mailfrom'] = 'Cursus interretialis, quo in cursibus uti';
$lang['gzip_output'] = 'gzip Argumentum-Codificans xhtml uti';
-$lang['gdlib'] = 'GD Lib uersio';
+$lang['gdlib'] = 'GD Lib forma';
$lang['im_convert'] = 'Domicilium machinae ImageMagick\'s';
$lang['jpg_quality'] = 'JPG compressio colorum (0-100)';
$lang['subscribers'] = 'Inscriptionis paginarum auxilium aptus facere';
@@ -148,7 +149,7 @@ $lang['deaccent_o_0'] = 'ex';
$lang['deaccent_o_1'] = 'accentum tollere';
$lang['deaccent_o_2'] = 'Latinis litteris';
$lang['gdlib_o_0'] = 'GD Lib inepta';
-$lang['gdlib_o_1'] = 'Versio 1.x';
+$lang['gdlib_o_1'] = 'Forma 1.x';
$lang['gdlib_o_2'] = 'Machinatione inspicere';
$lang['rss_type_o_rss'] = 'RSS 0.91';
$lang['rss_type_o_rss1'] = 'RSS 1.0';
diff --git a/lib/plugins/config/lang/ru/intro.txt b/lib/plugins/config/lang/ru/intro.txt
index c66a69e64..a629d9332 100644
--- a/lib/plugins/config/lang/ru/intro.txt
+++ b/lib/plugins/config/lang/ru/intro.txt
@@ -1,9 +1,9 @@
====== Настройки вики ======
-Здесь вы можете изменить настройки вашей «ДокуВики». Для справки по поводу конкретных опций смотрите [[doku>config]]. Дополнительные детали об этом плагине доступны здесь: [[doku>plugin:config]].
+Здесь вы можете изменить настройки своей «ДокуВики». Для справки по поводу конкретных опций смотрите [[doku>config]]. Дополнительные детали об этом плагине доступны здесь: [[doku>plugin:config]].
Настройки, отображаемые на светло-красном фоне, защищены от изменений и не могут быть отредактированы с помощью этого плагина. Голубым фоном отмечены настройки со значениями по умолчанию, а белым фоном — настройки, которые были локально изменены для этой конкретной «ДокуВики». Как голубые, так и белые настройки доступны для изменения.
-Не забудьте нажать кнопку **Сохранить** перед тем, как покинуть эту страницу, иначе все ваши изменения будут потеряны.
+Не забудьте нажать кнопку «**Сохранить**» перед тем, как покинуть эту страницу, иначе все ваши изменения будут потеряны.
diff --git a/lib/plugins/config/lang/ru/lang.php b/lib/plugins/config/lang/ru/lang.php
index 167c54eea..5e624eda0 100644
--- a/lib/plugins/config/lang/ru/lang.php
+++ b/lib/plugins/config/lang/ru/lang.php
@@ -16,11 +16,10 @@
* @author Aleksandr Selivanov <alexgearbox@gmail.com>
*/
$lang['menu'] = 'Настройки вики';
-$lang['error'] = 'Настройки не были сохранены из-за ошибки в одном из значений. Пожалуйста, проверьте ваши изменения и попробуйте еще раз.<br />Неправильные значения будут обведены красной рамкой.';
+$lang['error'] = 'Настройки не были сохранены из-за ошибки в одном из значений. Пожалуйста, проверьте свои изменения и попробуйте ещё раз.<br />Неправильные значения будут обведены красной рамкой.';
$lang['updated'] = 'Настройки успешно сохранены.';
$lang['nochoice'] = '(нет других вариантов)';
-$lang['locked'] = 'Файл настройки недоступен для изменения. Если это не специально, <br />
-убедитесь, что файл локальной настройки имеет правильное имя и права доступа.';
+$lang['locked'] = 'Файл настройки недоступен для изменения. Если это не специально, <br />убедитесь, что файл локальной настройки имеет правильное имя и права доступа.';
$lang['danger'] = 'Внимание: изменение этой опции может сделать вашу вики и меню конфигурации недоступными.';
$lang['warning'] = 'Предостережение: изменение этой опции может вызвать непредсказуемое поведение.';
$lang['security'] = 'Предостережение по безопасности: изменение этой опции может вызвать риск, связанный с безопасностью.';
@@ -63,7 +62,7 @@ $lang['phpok'] = 'Разрешить PHP';
$lang['dformat'] = 'Формат даты и времени';
$lang['signature'] = 'Шаблон подписи';
$lang['toptoclevel'] = 'Мин. уровень в содержании';
-$lang['tocminheads'] = 'Минимальное количество заголовков, при котором будет составлено содержание';
+$lang['tocminheads'] = 'Мин. количество заголовков, при котором будет составлено содержание';
$lang['maxtoclevel'] = 'Макс. уровень в содержании';
$lang['maxseclevel'] = 'Макс. уровень для правки';
$lang['camelcase'] = 'Использовать ВикиРегистр для ссылок';
@@ -84,22 +83,22 @@ $lang['authtype'] = 'Механизм аутентификации'
$lang['passcrypt'] = 'Метод шифрования пароля';
$lang['defaultgroup'] = 'Группа по умолчанию';
$lang['superuser'] = 'Суперпользователь — группа или пользователь с полным доступом ко всем страницам и функциям администрирования, независимо от установок ACL. Перечень разделяйте запятыми: user1,@group1,user2';
-$lang['manager'] = 'Менеджер — группа или пользователь с доступом к определенным функциям управления. Перечень разделяйте запятыми: user1,@group1,user2';
+$lang['manager'] = 'Менеджер — группа или пользователь с доступом к определённым функциям управления. Перечень разделяйте запятыми: user1,@group1,user2';
$lang['profileconfirm'] = 'Пароль для изменения профиля';
$lang['disableactions'] = 'Заблокировать операции «ДокуВики»';
$lang['disableactions_check'] = 'Проверка';
$lang['disableactions_subscription'] = 'Подписка/Отмена подписки';
$lang['disableactions_wikicode'] = 'Показ/экспорт исходного текста';
$lang['disableactions_other'] = 'Другие операции (через запятую)';
-$lang['sneaky_index'] = 'По умолчанию, «ДокуВики» показывает в индексе страниц все пространства имен. Включение этой опции скроет пространства имен, для которых пользователь не имеет прав чтения. Это может привести к скрытию доступных вложенных пространств имен и потере функциональности индекса страниц при некоторых конфигурациях прав доступа.';
+$lang['sneaky_index'] = 'По умолчанию, «ДокуВики» показывает в индексе страниц все пространства имён. Включение этой опции скроет пространства имён, для которых пользователь не имеет прав чтения. Это может привести к скрытию доступных вложенных пространств имён и потере функциональности индекса страниц при некоторых конфигурациях прав доступа.';
$lang['auth_security_timeout'] = 'Интервал для безопасности авторизации (сек.)';
$lang['securecookie'] = 'Должны ли куки (cookies), выставленные через HTTPS, отправляться браузером только через HTTPS. Отключите эту опцию в случае, когда только логин вашей вики передаётся через SSL, а обычный просмотр осуществляется в небезопасном режиме.';
$lang['xmlrpc'] = 'Включить/выключить XML-RPC интерфейс.';
-$lang['xmlrpcuser'] = 'Запретить XML-RPC доступ для списка групп и пользователей, перечисленных через запятую. Оставьте пустым, если хотите оставить доступ всем.';
-$lang['updatecheck'] = 'Проверять наличие обновлений и предупреждений о безопасности? Для этого «ДокуВики» потребуется связываться со <a href="http://www.splitbrain.org/">splitbrain.org</a>.';
+$lang['xmlrpcuser'] = 'Запретить XML-RPC-доступ для списка групп и пользователей, перечисленных через запятую. Оставьте пустым, если хотите оставить доступ всем.';
+$lang['updatecheck'] = 'Проверять наличие обновлений и предупреждений о безопасности? Для этого «ДокуВики» потребуется связываться с сайтом <a href="http://www.splitbrain.org/">splitbrain.org</a>.';
$lang['userewrite'] = 'Удобочитаемые адреса (URL)';
$lang['useslash'] = 'Использовать слэш';
-$lang['usedraft'] = 'Автоматически сохранять черновик в время правки';
+$lang['usedraft'] = 'Автоматически сохранять черновик во время правки';
$lang['sepchar'] = 'Разделитель слов в имени страницы';
$lang['canonical'] = 'Полные канонические адреса (URL)';
$lang['fnencode'] = 'Метод кодирования имён файлов, записанных не ASCII-символами.';
@@ -114,15 +113,15 @@ $lang['mailfrom'] = 'Электронный адрес вики (О
$lang['gzip_output'] = 'Использовать gzip-сжатие для xhtml';
$lang['gdlib'] = 'Версия LibGD';
$lang['im_convert'] = 'Путь к ImageMagick';
-$lang['jpg_quality'] = 'Качество сжатия JPG (0–100). Значение о умолчнию — 70.';
+$lang['jpg_quality'] = 'Качество сжатия JPG (0–100). Значение по умолчанию — 70.';
$lang['subscribers'] = 'Разрешить подписку на изменения';
-$lang['subscribe_time'] = 'Интервал рассылки подписок и сводок (сек.); Должен быть меньше, чем значение, указанное в recent_days.';
+$lang['subscribe_time'] = 'Интервал рассылки подписок и сводок (сек.). Должен быть меньше, чем значение, указанное в recent_days.';
$lang['compress'] = 'Сжимать файлы CSS и javascript';
$lang['hidepages'] = 'Скрыть страницы (рег. выражение)';
$lang['send404'] = 'Посылать «HTTP404/Page Not Found»';
$lang['sitemap'] = 'Число дней, через которое нужно создавать (обновлять) карту сайта для поисковиков (Гугл, Яндекс и др.)';
$lang['broken_iua'] = 'Возможно, функция ignore_user_abort не работает в вашей системе? Это может привести к потере функциональности индексирования поиска. Эта проблема присутствует, например, в IIS+PHP/CGI. Для дополнительной информации смотрите <a href="http://bugs.splitbrain.org/?do=details&amp;task_id=852">баг 852</a>.';
-$lang['xsendfile'] = 'Используете заголовок X-Sendfile для загрузки файлов на вебсервер? Ваш вебсервер должен поддерживать это.';
+$lang['xsendfile'] = 'Используете заголовок X-Sendfile для загрузки файлов на веб-сервер? Ваш веб-сервер должен поддерживать это.';
$lang['renderer_xhtml'] = 'Обработчик основного (xhtml) вывода вики';
$lang['renderer__core'] = '%s (ядро dokuwiki)';
$lang['renderer__plugin'] = '%s (плагин)';
@@ -138,18 +137,18 @@ $lang['target____interwiki'] = 'target для ссылок между вики
$lang['target____extern'] = 'target для внешних ссылок';
$lang['target____media'] = 'target для ссылок на медиафайлы';
$lang['target____windows'] = 'target для ссылок на сетевые каталоги';
-$lang['proxy____host'] = 'proxy - адрес';
-$lang['proxy____port'] = 'proxy - порт';
-$lang['proxy____user'] = 'proxy - имя пользователя';
-$lang['proxy____pass'] = 'proxy - пароль';
-$lang['proxy____ssl'] = 'proxy - ssl';
+$lang['proxy____host'] = 'proxy-адрес';
+$lang['proxy____port'] = 'proxy-порт';
+$lang['proxy____user'] = 'proxy-имя пользователя';
+$lang['proxy____pass'] = 'proxy-пароль';
+$lang['proxy____ssl'] = 'proxy-ssl';
$lang['proxy____except'] = 'Регулярное выражение для адресов (URL), для которых прокси должен быть пропущен.';
$lang['safemodehack'] = 'Включить обход safemode (хак)';
-$lang['ftp____host'] = 'ftp - адрес';
-$lang['ftp____port'] = 'ftp - порт';
-$lang['ftp____user'] = 'ftp - имя пользователя';
-$lang['ftp____pass'] = 'ftp - пароль';
-$lang['ftp____root'] = 'ftp - корневая директория';
+$lang['ftp____host'] = 'ftp-адрес';
+$lang['ftp____port'] = 'ftp-порт';
+$lang['ftp____user'] = 'ftp-имя пользователя';
+$lang['ftp____pass'] = 'ftp-пароль';
+$lang['ftp____root'] = 'ftp-корневая директория';
$lang['license_o_'] = 'Не выбрано';
$lang['typography_o_0'] = 'нет';
$lang['typography_o_1'] = 'Только двойные кавычки';
@@ -185,10 +184,10 @@ $lang['xsendfile_o_2'] = 'Стандартный заголовок X-Se
$lang['xsendfile_o_3'] = 'Проприетарный заголовок Nginx X-Accel-Redirect';
$lang['showuseras_o_loginname'] = 'Логин';
$lang['showuseras_o_username'] = 'Полное имя пользователя';
-$lang['showuseras_o_email'] = 'Адрес электронной почты пользователя (зашифрован согласно настройкам mailguard)';
-$lang['showuseras_o_email_link'] = 'Адрес электронной почты пользователя в виде ссылки mailto:';
+$lang['showuseras_o_email'] = 'Адрес электропочты в шифрованном виде (см. mailguard)';
+$lang['showuseras_o_email_link'] = 'Адрес электропочты в виде ссылки mailto:';
$lang['useheading_o_0'] = 'Никогда';
$lang['useheading_o_navigation'] = 'Только навигация';
$lang['useheading_o_content'] = 'Только содержимое вики';
$lang['useheading_o_1'] = 'Всегда';
-$lang['readdircache'] = 'Максимальное время жизни кэша readdir (сек)';
+$lang['readdircache'] = 'Максимальное время жизни кэша readdir (сек.)';
diff --git a/lib/plugins/config/lang/sl/lang.php b/lib/plugins/config/lang/sl/lang.php
index 52b88a053..5b5b3d3d8 100644
--- a/lib/plugins/config/lang/sl/lang.php
+++ b/lib/plugins/config/lang/sl/lang.php
@@ -4,6 +4,7 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
$lang['lang'] = 'Jezik';
$lang['template'] = 'Predloga';
diff --git a/lib/plugins/config/lang/tr/lang.php b/lib/plugins/config/lang/tr/lang.php
index 9929c663e..6d7d7cc2e 100644
--- a/lib/plugins/config/lang/tr/lang.php
+++ b/lib/plugins/config/lang/tr/lang.php
@@ -2,11 +2,10 @@
/**
* Turkish language file
*
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['menu'] = 'Site Ayarları';
$lang['error'] = 'Ayarlar yanlış bir değer girildiği için güncellenemedi. Lütfen değişikliklerinizi gözden geçirin ve tekrar gönderin.
diff --git a/lib/plugins/config/settings/config.class.php b/lib/plugins/config/settings/config.class.php
index 4f2129c70..01f15a54e 100644
--- a/lib/plugins/config/settings/config.class.php
+++ b/lib/plugins/config/settings/config.class.php
@@ -342,8 +342,8 @@ if (!class_exists('setting')) {
var $_cautionList = array(
'basedir' => 'danger', 'baseurl' => 'danger', 'savedir' => 'danger', 'useacl' => 'danger', 'authtype' => 'danger', 'superuser' => 'danger', 'userewrite' => 'danger',
- 'start' => 'warning', 'camelcase' => 'warning', 'deaccent' => 'warning', 'sepchar' => 'warning', 'compression' => 'warning', 'xsendfile' => 'warning', 'renderer_xhtml' => 'warning',
- 'allowdebug' => 'security', 'htmlok' => 'security', 'phpok' => 'security', 'iexssprotect' => 'security', 'xmlrpc' => 'security', 'fnencode' => 'warning'
+ 'start' => 'warning', 'camelcase' => 'warning', 'deaccent' => 'warning', 'sepchar' => 'warning', 'compression' => 'warning', 'xsendfile' => 'warning', 'renderer_xhtml' => 'warning', 'fnencode' => 'warning',
+ 'allowdebug' => 'security', 'htmlok' => 'security', 'phpok' => 'security', 'iexssprotect' => 'security', 'xmlrpc' => 'security', 'fullpath' => 'security'
);
function setting($key, $params=NULL) {
@@ -616,8 +616,25 @@ if (!class_exists('setting_numeric')) {
// This allows for many PHP syntax errors...
// var $_pattern = '/^[-+\/*0-9 ]*$/';
// much more restrictive, but should eliminate syntax errors.
- var $_pattern = '/^[-]?[0-9]+(?:[-+*][0-9]+)*$/';
- //FIXME - make the numeric error checking better.
+ var $_pattern = '/^[-+]? *[0-9]+ *(?:[-+*] *[0-9]+ *)*$/';
+ var $_min = null;
+ var $_max = null;
+
+ function update($input) {
+ $local = $this->_local;
+ $valid = parent::update($input);
+ if ($valid && !(is_null($this->_min) && is_null($this->_max))) {
+ $numeric_local = (int) eval('return '.$this->_local.';');
+ if ((!is_null($this->_min) && $numeric_local < $this->_min) ||
+ (!is_null($this->_max) && $numeric_local > $this->_max)) {
+ $this->_error = true;
+ $this->_input = $input;
+ $this->_local = $local;
+ $valid = false;
+ }
+ }
+ return $valid;
+ }
function out($var, $fmt='php') {
diff --git a/lib/plugins/config/settings/config.metadata.php b/lib/plugins/config/settings/config.metadata.php
index 331da5ab8..ca2cd0c12 100644
--- a/lib/plugins/config/settings/config.metadata.php
+++ b/lib/plugins/config/settings/config.metadata.php
@@ -16,6 +16,7 @@
* '' - default class ('setting'), textarea, minimal input validation, setting output in quotes
* 'string' - single line text input, minimal input validation, setting output in quotes
* 'numeric' - text input, accepts numbers and arithmetic operators, setting output without quotes
+ * if given the '_min' and '_max' parameters are used for validation
* 'numericopt' - like above, but accepts empty values
* 'onoff' - checkbox input, setting output 0|1
* 'multichoice' - select input (single choice), setting output with quotes, required _choices parameter
@@ -54,6 +55,8 @@
* '_combine' - complimentary output setting values which can be combined into a single display checkbox
* optional for 'multicheckbox', ignored by other classes
* '_code' - encoding method to use, accepted values: 'base64','uuencode','plain'. defaults to plain.
+ * '_min' - minimum numeric value, optional for 'numeric' and 'numericopt', ignored by others
+ * '_max' - maximum numeric value, optional for 'numeric' and 'numericopt', ignored by others
*
* @author Chris Smith <chris@jalakai.co.uk>
*/
@@ -98,7 +101,7 @@ $meta['allowdebug'] = array('onoff');
$meta['_display'] = array('fieldset');
$meta['recent'] = array('numeric');
-$meta['breadcrumbs'] = array('numeric');
+$meta['breadcrumbs'] = array('numeric','_min' => 0);
$meta['youarehere'] = array('onoff');
$meta['fullpath'] = array('onoff');
$meta['typography'] = array('multichoice','_choices' => array(0,1,2));
@@ -119,7 +122,7 @@ $meta['_authentication'] = array('fieldset');
$meta['useacl'] = array('onoff');
$meta['autopasswd'] = array('onoff');
$meta['authtype'] = array('authtype');
-$meta['passcrypt'] = array('multichoice','_choices' => array('smd5','md5','apr1','sha1','ssha','crypt','mysql','my411','kmd5'));
+$meta['passcrypt'] = array('multichoice','_choices' => array('smd5','md5','apr1','sha1','ssha','crypt','mysql','my411','kmd5','pmd5','hmd5'));
$meta['defaultgroup']= array('string');
$meta['superuser'] = array('string');
$meta['manager'] = array('string');
@@ -174,6 +177,7 @@ $meta['canonical'] = array('onoff');
$meta['fnencode'] = array('multichoice','_choices' => array('url','safe','utf-8'));
$meta['autoplural'] = array('onoff');
$meta['mailfrom'] = array('richemail');
+$meta['mailprefix'] = array('string');
$meta['compress'] = array('onoff');
$meta['gzip_output'] = array('onoff');
$meta['hidepages'] = array('string');
diff --git a/lib/plugins/info/syntax.php b/lib/plugins/info/syntax.php
index ba2831a90..026a438bb 100644
--- a/lib/plugins/info/syntax.php
+++ b/lib/plugins/info/syntax.php
@@ -253,4 +253,4 @@ class syntax_plugin_info extends DokuWiki_Syntax_Plugin {
}
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/plugin/lang/cs/lang.php b/lib/plugins/plugin/lang/cs/lang.php
index c15a5ca21..54de0ff18 100644
--- a/lib/plugins/plugin/lang/cs/lang.php
+++ b/lib/plugins/plugin/lang/cs/lang.php
@@ -26,7 +26,7 @@ $lang['source'] = 'Zdroj:';
$lang['unknown'] = 'neznámý';
$lang['updating'] = 'Aktualizuji ...';
$lang['updated'] = 'Modul %s úspěšně aktualizován';
-$lang['updates'] = 'Následjící pluginy byly úspěšně aktualizovány';
+$lang['updates'] = 'Následující pluginy byly úspěšně aktualizovány';
$lang['update_none'] = 'Žádné aktualizace nenalezeny.';
$lang['deleting'] = 'Probíhá mazání ...';
$lang['deleted'] = 'Plugin %s smazán.';
@@ -49,7 +49,7 @@ $lang['error_download'] = 'Nelze stáhnout soubor s pluginem: %s';
$lang['error_badurl'] = 'URL je zřejmě chybná - nelze z ní určit název souboru';
$lang['error_dircreate'] = 'Nelze vytvořit dočasný adresář ke stažení dat';
$lang['error_decompress'] = 'Správce pluginů nemůže rozbalit stažený soubor. Toto může být způsobeno chybou při stahování. Můžete se pokusit stahování opakovat. Chyba může být také v kompresním formátu souboru. V tom případě bude nutné stáhnout a nainstalovat plugin ručně.';
-$lang['error_copy'] = 'Došlo k chybě při instalaci pluginu <em>%s</em>. Je možné, že na disku není volné místo, nebo mohou být špatně nastavena přístupová práva. Pozor, mohlo dojít k častečné a tudíž chybné instalaci pluginu a tím může být ohrožena stabilita wiki.';
+$lang['error_copy'] = 'Došlo k chybě při instalaci pluginu <em>%s</em>. Je možné, že na disku není volné místo, nebo mohou být špatně nastavena přístupová práva. Pozor, mohlo dojít k částečné a tudíž chybné instalaci pluginu a tím může být ohrožena stabilita wiki.';
$lang['error_delete'] = 'Došlo k chybě při pokusu o smazání pluginu <em>%s</em>. Nejspíše je chyba v nastavení přístupových práv k některým souborům či adresářům.';
$lang['enabled'] = 'Plugin %s aktivován.';
$lang['notenabled'] = 'Plugin %s nelze aktivovat, zkontrolujte práva k souborům.';
diff --git a/lib/plugins/plugin/lang/de-informal/lang.php b/lib/plugins/plugin/lang/de-informal/lang.php
index 65050b896..3ba729fd6 100644
--- a/lib/plugins/plugin/lang/de-informal/lang.php
+++ b/lib/plugins/plugin/lang/de-informal/lang.php
@@ -6,6 +6,7 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Plugins verwalten';
$lang['download'] = 'Herunterladen und installieren einer neuen Erweiterung';
diff --git a/lib/plugins/plugin/lang/de/lang.php b/lib/plugins/plugin/lang/de/lang.php
index e981f4a60..6f785168b 100644
--- a/lib/plugins/plugin/lang/de/lang.php
+++ b/lib/plugins/plugin/lang/de/lang.php
@@ -14,6 +14,8 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Plugins verwalten';
$lang['download'] = 'Neues Plugin herunterladen und installieren';
diff --git a/lib/plugins/plugin/lang/en/lang.php b/lib/plugins/plugin/lang/en/lang.php
index e575d3d67..ccbd207e9 100644
--- a/lib/plugins/plugin/lang/en/lang.php
+++ b/lib/plugins/plugin/lang/en/lang.php
@@ -74,4 +74,4 @@ $lang['notenabled'] = 'Plugin %s could not be enabled, check file permissi
$lang['disabled'] = 'Plugin %s disabled.';
$lang['notdisabled'] = 'Plugin %s could not be disabled, check file permissions.';
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/plugin/lang/he/lang.php b/lib/plugins/plugin/lang/he/lang.php
index c6e462193..47253e335 100644
--- a/lib/plugins/plugin/lang/he/lang.php
+++ b/lib/plugins/plugin/lang/he/lang.php
@@ -7,6 +7,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['menu'] = 'ניהול הרחבות';
$lang['download'] = 'הורדת והתקנת הרחבה חדשה';
diff --git a/lib/plugins/plugin/lang/ko/lang.php b/lib/plugins/plugin/lang/ko/lang.php
index af14a0cd2..72c04ddab 100644
--- a/lib/plugins/plugin/lang/ko/lang.php
+++ b/lib/plugins/plugin/lang/ko/lang.php
@@ -7,6 +7,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['menu'] = '플러그인 관리자';
$lang['download'] = '새로운 플러그인 다운로드 및 설치';
diff --git a/lib/plugins/plugin/lang/la/admin_plugin.txt b/lib/plugins/plugin/lang/la/admin_plugin.txt
index 1a361140c..2a41977fc 100644
--- a/lib/plugins/plugin/lang/la/admin_plugin.txt
+++ b/lib/plugins/plugin/lang/la/admin_plugin.txt
@@ -1,3 +1,3 @@
====== Addendorum Administratio ======
-In hac pagina omnia uicis [[doku>plugins|plugins]] mutare et administrare potes. Ut addenda capere et his uti, in scrinio addendorum scribere et legere potest. \ No newline at end of file
+In hac pagina omnia uicis [[doku>plugins|plugins]] mutare et administrare potes. Vt addenda capere et his uti, in scrinio addendorum scribere et legere potest. \ No newline at end of file
diff --git a/lib/plugins/plugin/lang/la/lang.php b/lib/plugins/plugin/lang/la/lang.php
index 021dc84d5..cd2d81cbd 100644
--- a/lib/plugins/plugin/lang/la/lang.php
+++ b/lib/plugins/plugin/lang/la/lang.php
@@ -2,8 +2,9 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
-$lang['menu'] = 'Administrationis addenda';
+$lang['menu'] = 'Addendorum administratio';
$lang['download'] = 'Noua addenda cape';
$lang['manage'] = 'Addenta in usu';
$lang['btn_info'] = 'Notae';
diff --git a/lib/plugins/plugin/lang/pt-br/admin_plugin.txt b/lib/plugins/plugin/lang/pt-br/admin_plugin.txt
index 1809bb585..9e49f5136 100644
--- a/lib/plugins/plugin/lang/pt-br/admin_plugin.txt
+++ b/lib/plugins/plugin/lang/pt-br/admin_plugin.txt
@@ -1,3 +1,3 @@
====== Gerenciamento de Plug-ins ======
-Nesta página você pode gerenciar tudo relacionado aos [[doku>plug-ins|plug-ins]] do DokuWiki. Para você baixar e instalar um plug-in o servidor web deve ter permissão de escrita na pasta onde ficam os plug-ins.
+Nesta página você pode gerenciar tudo relacionado aos [[doku>plugins|plug-ins]] do DokuWiki. Para você baixar e instalar um plug-in o servidor web deve ter permissão de escrita na pasta onde ficam os plug-ins.
diff --git a/lib/plugins/plugin/lang/ru/lang.php b/lib/plugins/plugin/lang/ru/lang.php
index a33f95418..ed1fc22b3 100644
--- a/lib/plugins/plugin/lang/ru/lang.php
+++ b/lib/plugins/plugin/lang/ru/lang.php
@@ -30,11 +30,11 @@ $lang['lastupdate'] = 'Последнее обновление:';
$lang['source'] = 'Источник:';
$lang['unknown'] = 'неизвестно';
$lang['updating'] = 'Обновление...';
-$lang['updated'] = 'Плагин %s успешно обновлен';
+$lang['updated'] = 'Плагин %s успешно обновлён';
$lang['updates'] = 'Следующие плагины были успешно обновлены';
$lang['update_none'] = 'Обновления не найдены.';
$lang['deleting'] = 'Удаление...';
-$lang['deleted'] = 'Плагин %s удален.';
+$lang['deleted'] = 'Плагин %s удалён.';
$lang['downloading'] = 'Скачивание...';
$lang['downloaded'] = 'Плагин %s успешно установлен';
$lang['downloads'] = 'Следующие плагины были успешно установлены:';
@@ -50,9 +50,9 @@ $lang['author'] = 'Автор:';
$lang['www'] = 'Странца:';
$lang['error'] = 'Произошла неизвестная ошибка.';
$lang['error_download'] = 'Не могу скачать файл плагина: %s';
-$lang['error_badurl'] = 'Возможно, неправильный адрес — не могу определить имя файла из адреса';
+$lang['error_badurl'] = 'Возможно неправильный адрес — не могу определить имя файла из адреса';
$lang['error_dircreate'] = 'Не могу создать временную директорию для скачивания';
-$lang['error_decompress'] = 'Менеджеру плагинов не удалось распаковать скачанный файл. Это может быть результатом ошибки при скачивании, в этом случае вы можете попробовать снова; или же плагин упакован неизвестным архиватором, тогда вам необходимо скачать и установить плагин вручную.';
+$lang['error_decompress'] = 'Менеджеру плагинов не удалось распаковать скачанный файл. Это может быть результатом ошибки при скачивании, в этом случае вы можете попробовать снова, или же плагин упакован неизвестным архиватором, тогда вам необходимо скачать и установить плагин вручную.';
$lang['error_copy'] = 'Произошла ошибка копирования при попытке установки файлов для плагина <em>%s</em>: переполнение диска или неправильные права доступа. Это могло привести к частичной установке плагина и неустойчивости вашей вики.';
$lang['error_delete'] = 'Произошла ошибка при попытке удалить плагин <em>%s</em>. Наиболее вероятно, что нет необходимых прав доступа к файлам или директориям';
$lang['enabled'] = 'Плагин %s включён.';
diff --git a/lib/plugins/plugin/lang/sl/lang.php b/lib/plugins/plugin/lang/sl/lang.php
index 9423e4e75..41d857979 100644
--- a/lib/plugins/plugin/lang/sl/lang.php
+++ b/lib/plugins/plugin/lang/sl/lang.php
@@ -4,6 +4,7 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
$lang['btn_delete'] = 'Izbriši';
$lang['btn_settings'] = 'Nastavitve';
diff --git a/lib/plugins/plugin/lang/tr/lang.php b/lib/plugins/plugin/lang/tr/lang.php
index 28db9109d..9a655e400 100644
--- a/lib/plugins/plugin/lang/tr/lang.php
+++ b/lib/plugins/plugin/lang/tr/lang.php
@@ -2,11 +2,10 @@
/**
* Turkish language file
*
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['menu'] = 'Eklenti Yönetimi';
$lang['download'] = 'Yeni bir eklenti indirip kur';
diff --git a/lib/plugins/popularity/action.php b/lib/plugins/popularity/action.php
new file mode 100644
index 000000000..bf11efba6
--- /dev/null
+++ b/lib/plugins/popularity/action.php
@@ -0,0 +1,57 @@
+<?php
+/**
+ * Popularity Feedback Plugin
+ *
+ * @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
+ */
+
+require_once(DOKU_PLUGIN.'action.php');
+require_once(DOKU_PLUGIN.'popularity/admin.php');
+
+class action_plugin_popularity extends Dokuwiki_Action_Plugin {
+ var $helper;
+
+ function action_plugin_popularity(){
+ $this->helper = $this->loadHelper('popularity', false);
+ }
+
+ /**
+ * Register its handlers with the dokuwiki's event controller
+ */
+ function register(&$controller) {
+ $controller->register_hook('INDEXER_TASKS_RUN', 'AFTER', $this, '_autosubmit', array());
+ }
+
+ function _autosubmit(&$event, $param){
+ //Do we have to send the data now
+ if ( !$this->helper->isAutosubmitEnabled() || $this->_isTooEarlyToSubmit() ){
+ return;
+ }
+
+ //Actually send it
+ $status = $this->helper->sendData( $this->helper->gatherAsString() );
+
+
+ if ( $status !== '' ){
+ //If an error occured, log it
+ io_saveFile( $this->helper->autosubmitErrorFile, $status );
+ } else {
+ //If the data has been sent successfully, previous log of errors are useless
+ @unlink($this->helper->autosubmitErrorFile);
+ //Update the last time we sent data
+ touch ( $this->helper->autosubmitFile );
+ }
+
+ $event->stopPropagation();
+ $event->preventDefault();
+ }
+
+ /**
+ * Check if it's time to send autosubmit data
+ * (we should have check if autosubmit is enabled first)
+ */
+ function _isTooEarlyToSubmit(){
+ $lastSubmit = $this->helper->lastSentTime();
+ return $lastSubmit + 24*60*60*30 > time();
+ }
+}
diff --git a/lib/plugins/popularity/admin.php b/lib/plugins/popularity/admin.php
index 71ea40799..40c3f5452 100644
--- a/lib/plugins/popularity/admin.php
+++ b/lib/plugins/popularity/admin.php
@@ -13,21 +13,15 @@ if(!defined('DOKU_INC')) die();
* need to inherit from this class
*/
class admin_plugin_popularity extends DokuWiki_Admin_Plugin {
- var $version = '2010-09-17';
+ var $version;
+ var $helper;
+ var $sentStatus = null;
+ function admin_plugin_popularity(){
+ $this->helper = $this->loadHelper('popularity', false);
- /**
- * return some info
- */
- function getInfo(){
- return array(
- 'author' => 'Andreas Gohr',
- 'email' => 'andi@splitbrain.org',
- 'date' => $this->version,
- 'name' => 'Popularity Feedback Plugin',
- 'desc' => 'Send anonymous data about your wiki to the developers.',
- 'url' => 'http://www.dokuwiki.org/plugin:popularity',
- );
+ $pluginInfo = $this->getInfo();
+ $this->version = $pluginInfo['date'];
}
/**
@@ -56,204 +50,99 @@ class admin_plugin_popularity extends DokuWiki_Admin_Plugin {
* handle user request
*/
function handle() {
+ //Send the data
+ if ( isset($_REQUEST['data']) ){
+ $this->sentStatus = $this->helper->sendData( $_REQUEST['data'] );
+ if ( $this->sentStatus === '' ){
+ //Update the last time we sent the data
+ touch ( $this->helper->popularityLastSubmitFile );
+ }
+ //Deal with the autosubmit option
+ $this->_enableAutosubmit( isset($_REQUEST['autosubmit']) );
+ }
}
/**
- * Output HTML form
+ * Enable or disable autosubmit
+ * @param bool $enable If TRUE, it will enable autosubmit. Else, it will disable it.
*/
- function html() {
- echo $this->locale_xhtml('intro');
-
- flush();
- $data = $this->_gather();
- echo '<form method="post" action="http://update.dokuwiki.org/popularity.php" accept-charset="utf-8">';
- echo '<fieldset style="width: 60%;">';
- echo '<textarea class="edit" rows="10" cols="80" readonly="readonly" name="data">';
- foreach($data as $key => $val){
- if(is_array($val)) foreach($val as $v){
- echo hsc($key)."\t".hsc($v)."\n";
- }else{
- echo hsc($key)."\t".hsc($val)."\n";
- }
+ function _enableAutosubmit( $enable ){
+ if ( $enable ){
+ io_saveFile( $this->helper->autosubmitFile, ' ');
+ } else {
+ @unlink($this->helper->autosubmitFile);
}
- echo '</textarea><br />';
- echo '<input type="submit" class="button" value="'.$this->getLang('submit').'"/>';
- echo '</fieldset>';
- echo '</form>';
-
-// dbg($data);
}
-
/**
- * Gather all information
+ * Output HTML form
*/
- function _gather(){
- global $conf;
- global $auth;
- $data = array();
- $phptime = ini_get('max_execution_time');
- @set_time_limit(0);
-
- // version
- $data['anon_id'] = md5(auth_cookiesalt());
- $data['version'] = getVersion();
- $data['popversion'] = $this->version;
- $data['language'] = $conf['lang'];
- $data['now'] = time();
-
- // some config values
- $data['conf_useacl'] = $conf['useacl'];
- $data['conf_authtype'] = $conf['authtype'];
- $data['conf_template'] = $conf['template'];
-
- // number and size of pages
- $list = array();
- search($list,$conf['datadir'],array($this,'_search_count'),'','');
- $data['page_count'] = $list['file_count'];
- $data['page_size'] = $list['file_size'];
- $data['page_biggest'] = $list['file_max'];
- $data['page_smallest'] = $list['file_min'];
- $data['page_nscount'] = $list['dir_count'];
- $data['page_nsnest'] = $list['dir_nest'];
- if($list['file_count']) $data['page_avg'] = $list['file_size'] / $list['file_count'];
- $data['page_oldest'] = $list['file_oldest'];
- unset($list);
-
- // number and size of media
- $list = array();
- search($list,$conf['mediadir'],array($this,'_search_count'),array('all'=>true));
- $data['media_count'] = $list['file_count'];
- $data['media_size'] = $list['file_size'];
- $data['media_biggest'] = $list['file_max'];
- $data['media_smallest'] = $list['file_min'];
- $data['media_nscount'] = $list['dir_count'];
- $data['media_nsnest'] = $list['dir_nest'];
- if($list['file_count']) $data['media_avg'] = $list['file_size'] / $list['file_count'];
- unset($list);
-
- // number and size of cache
- $list = array();
- search($list,$conf['cachedir'],array($this,'_search_count'),array('all'=>true));
- $data['cache_count'] = $list['file_count'];
- $data['cache_size'] = $list['file_size'];
- $data['cache_biggest'] = $list['file_max'];
- $data['cache_smallest'] = $list['file_min'];
- if($list['file_count']) $data['cache_avg'] = $list['file_size'] / $list['file_count'];
- unset($list);
-
- // number and size of index
- $list = array();
- search($list,$conf['indexdir'],array($this,'_search_count'),array('all'=>true));
- $data['index_count'] = $list['file_count'];
- $data['index_size'] = $list['file_size'];
- $data['index_biggest'] = $list['file_max'];
- $data['index_smallest'] = $list['file_min'];
- if($list['file_count']) $data['index_avg'] = $list['file_size'] / $list['file_count'];
- unset($list);
-
- // number and size of meta
- $list = array();
- search($list,$conf['metadir'],array($this,'_search_count'),array('all'=>true));
- $data['meta_count'] = $list['file_count'];
- $data['meta_size'] = $list['file_size'];
- $data['meta_biggest'] = $list['file_max'];
- $data['meta_smallest'] = $list['file_min'];
- if($list['file_count']) $data['meta_avg'] = $list['file_size'] / $list['file_count'];
- unset($list);
-
- // number and size of attic
- $list = array();
- search($list,$conf['olddir'],array($this,'_search_count'),array('all'=>true));
- $data['attic_count'] = $list['file_count'];
- $data['attic_size'] = $list['file_size'];
- $data['attic_biggest'] = $list['file_max'];
- $data['attic_smallest'] = $list['file_min'];
- if($list['file_count']) $data['attic_avg'] = $list['file_size'] / $list['file_count'];
- $data['attic_oldest'] = $list['file_oldest'];
- unset($list);
+ function html() {
+ if ( ! isset($_REQUEST['data']) ){
+ echo $this->locale_xhtml('intro');
+
+ //If there was an error the last time we tried to autosubmit, warn the user
+ if ( $this->helper->isAutoSubmitEnabled() ){
+ if ( @file_exists($this->helper->autosubmitErrorFile) ){
+ echo $this->getLang('autosubmitError');
+ echo io_readFile( $this->helper->autosubmitErrorFile );
+ }
+ }
- // user count
- if($auth && $auth->canDo('getUserCount')){
- $data['user_count'] = $auth->getUserCount();
- }
+ flush();
+ echo $this->buildForm('server');
- // calculate edits per day
- $list = @file($conf['metadir'].'/_dokuwiki.changes');
- $count = count($list);
- if($count > 2){
- $first = (int) substr(array_shift($list),0,10);
- $last = (int) substr(array_pop($list),0,10);
- $dur = ($last - $first)/(60*60*24); // number of days in the changelog
- $data['edits_per_day'] = $count/$dur;
+ //Print the last time the data was sent
+ $lastSent = $this->helper->lastSentTime();
+ if ( $lastSent !== 0 ){
+ echo $this->getLang('lastSent') . datetime_h($lastSent);
+ }
+ } else {
+ //If we just submitted the form
+ if ( $this->sentStatus === '' ){
+ //If we successfully sent the data
+ echo $this->locale_xhtml('submitted');
+ } else {
+ //If we failed to submit the data, try directly with the browser
+ echo $this->getLang('submissionFailed') . $this->sentStatus . '<br />';
+ echo $this->getLang('submitDirectly');
+ echo $this->buildForm('browser', $_REQUEST['data']);
+ }
}
- unset($list);
-
- // plugins
- $data['plugin'] = plugin_list();
-
- // pcre info
- if(defined('PCRE_VERSION')) $data['pcre_version'] = PCRE_VERSION;
- $data['pcre_backtrack'] = ini_get('pcre.backtrack_limit');
- $data['pcre_recursion'] = ini_get('pcre.recursion_limit');
-
- // php info
- $data['os'] = PHP_OS;
- $data['webserver'] = $_SERVER['SERVER_SOFTWARE'];
- $data['php_version'] = phpversion();
- $data['php_sapi'] = php_sapi_name();
- $data['php_memory'] = $this->_to_byte(ini_get('memory_limit'));
- $data['php_exectime'] = $phptime;
- $data['php_extension'] = get_loaded_extensions();
-
- return $data;
}
- function _search_count(&$data,$base,$file,$type,$lvl,$opts){
- // traverse
- if($type == 'd'){
- if($data['dir_nest'] < $lvl) $data['dir_nest'] = $lvl;
- $data['dir_count']++;
- return true;
- }
-
- //only search txt files if 'all' option not set
- if($opts['all'] || substr($file,-4) == '.txt'){
- $size = filesize($base.'/'.$file);
- $date = filemtime($base.'/'.$file);
- $data['file_count']++;
- $data['file_size'] += $size;
- if(!isset($data['file_min']) || $data['file_min'] > $size) $data['file_min'] = $size;
- if($data['file_max'] < $size) $data['file_max'] = $size;
- if(!isset($data['file_oldest']) || $data['file_oldest'] > $date) $data['file_oldest'] = $date;
- }
-
- return false;
- }
-
/**
- * Convert php.ini shorthands to byte
- *
- * @author <gilthans dot NO dot SPAM at gmail dot com>
- * @link http://de3.php.net/manual/en/ini.core.php#79564
+ * Build the form which presents the data to be sent
+ * @param string $submit How is the data supposed to be sent? (may be: 'browser' or 'server')
+ * @param string $data The popularity data, if it has already been computed. NULL otherwise.
+ * @return The form, as an html string
*/
- function _to_byte($v){
- $l = substr($v, -1);
- $ret = substr($v, 0, -1);
- switch(strtoupper($l)){
- case 'P':
- $ret *= 1024;
- case 'T':
- $ret *= 1024;
- case 'G':
- $ret *= 1024;
- case 'M':
- $ret *= 1024;
- case 'K':
- $ret *= 1024;
- break;
+ function buildForm($submissionMode, $data = null){
+ $url = ($submissionMode === 'browser' ? $this->helper->submitUrl : script());
+ if ( is_null($data) ){
+ $data = $this->helper->gatherAsString();
+ }
+
+ $form = '<form method="post" action="'. $url .'" accept-charset="utf-8">'
+ .'<fieldset style="width: 60%;">'
+ .'<textarea class="edit" rows="10" cols="80" readonly="readonly" name="data">'
+ .$data
+ .'</textarea><br />';
+
+ //If we submit via the server, we give the opportunity to suscribe to the autosubmission option
+ if ( $submissionMode !== 'browser' ){
+ $form .= '<label for="autosubmit">'
+ .'<input type="checkbox" name="autosubmit" id="autosubmit" '
+ .($this->helper->isAutosubmitEnabled() ? 'checked' : '' )
+ .'/>' . $this->getLang('autosubmit') .'<br />'
+ .'</label>'
+ .'<input type="hidden" name="do" value="admin">'
+ .'<input type="hidden" name="page" value="popularity">';
}
- return $ret;
+ $form .= '<input type="submit" class="button" value="'.$this->getLang('submit').'"/>'
+ .'</fieldset>'
+ .'</form>';
+ return $form;
}
}
diff --git a/lib/plugins/popularity/helper.php b/lib/plugins/popularity/helper.php
new file mode 100644
index 000000000..629d0bd67
--- /dev/null
+++ b/lib/plugins/popularity/helper.php
@@ -0,0 +1,291 @@
+<?php
+/**
+ * Popularity Feedback Plugin
+ *
+ * @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
+ */
+
+class helper_plugin_popularity extends Dokuwiki_Plugin {
+ /**
+ * The url where the data should be sent
+ */
+ var $submitUrl = 'http://update.dokuwiki.org/popularity.php';
+
+ /**
+ * Name of the file which determine if the the autosubmit is enabled,
+ * and when it was submited for the last time
+ */
+ var $autosubmitFile;
+
+ /**
+ * File where the last error which happened when we tried to autosubmit, will be log
+ */
+ var $autosubmitErrorFile;
+
+ /**
+ * Name of the file which determine when the popularity data was manually
+ * submitted for the last time
+ * (If this file doesn't exist, the data has never been sent)
+ */
+ var $popularityLastSubmitFile;
+
+
+ function helper_plugin_popularity(){
+ global $conf;
+ $this->autosubmitFile = $conf['cachedir'].'/autosubmit.txt';
+ $this->autosubmitErrorFile = $conf['cachedir'].'/autosubmitError.txt';
+ $this->popularityLastSubmitFile = $conf['cachedir'].'/lastSubmitTime.txt';
+ }
+
+ function getMethods(){
+ $result = array();
+ $result[] = array(
+ 'name' => 'isAutoSubmitEnabled',
+ 'desc' => 'Check if autosubmit is enabled',
+ 'params' => array(),
+ 'return' => array('result' => 'bool')
+ );
+ $result[] = array(
+ 'name' => 'sendData',
+ 'desc' => 'Send the popularity data',
+ 'params' => array('data' => 'string'),
+ 'return' => array()
+ );
+ $result[] = array(
+ 'name' => 'gatherAsString',
+ 'desc' => 'Gather the popularity data',
+ 'params' => array(),
+ 'return' => array('data' => 'string')
+ );
+ $result[] = array(
+ 'name' => 'lastSentTime',
+ 'desc' => 'Compute the last time popularity data was sent',
+ 'params' => 'array()',
+ 'return' => array('data' => 'int')
+ );
+ return $result;
+
+ }
+
+ /**
+ * Check if autosubmit is enabled
+ * @return TRUE if we should send data once a month, FALSE otherwise
+ */
+ function isAutoSubmitEnabled(){
+ return @file_exists($this->autosubmitFile);
+ }
+
+ /**
+ * Send the data, to the submit url
+ * @param string $data The popularity data
+ * @return An empty string if everything worked fine, a string describing the error otherwise
+ */
+ function sendData($data){
+ $error = '';
+ $httpClient = new DokuHTTPClient();
+ $status = $httpClient->sendRequest($this->submitUrl, $data, 'POST');
+ if ( ! $status ){
+ $error = $httpClient->error;
+ }
+ return $error;
+ }
+
+ /**
+ * Compute the last time the data was sent. If it has never been sent, we return 0.
+ */
+ function lastSentTime(){
+ $manualSubmission = @filemtime($this->popularityLastSubmitFile);
+ $autoSubmission = @filemtime($this->autosubmitFile);
+
+ return max((int) $manualSubmission, (int) $autoSubmission);
+ }
+
+ /**
+ * Gather all information
+ * @return The popularity data as a string
+ */
+ function gatherAsString(){
+ $data = $this->_gather();
+ $string = '';
+ foreach($data as $key => $val){
+ if(is_array($val)) foreach($val as $v){
+ $string .= hsc($key)."\t".hsc($v)."\n";
+ }else{
+ $string .= hsc($key)."\t".hsc($val)."\n";
+ }
+ }
+ return $string;
+ }
+
+ /**
+ * Gather all information
+ * @return The popularity data as an array
+ */
+ function _gather(){
+ global $conf;
+ global $auth;
+ $data = array();
+ $phptime = ini_get('max_execution_time');
+ @set_time_limit(0);
+
+ // version
+ $data['anon_id'] = md5(auth_cookiesalt());
+ $data['version'] = getVersion();
+ $data['popversion'] = $this->version;
+ $data['language'] = $conf['lang'];
+ $data['now'] = time();
+
+ // some config values
+ $data['conf_useacl'] = $conf['useacl'];
+ $data['conf_authtype'] = $conf['authtype'];
+ $data['conf_template'] = $conf['template'];
+
+ // number and size of pages
+ $list = array();
+ search($list,$conf['datadir'],array($this,'_search_count'),'','');
+ $data['page_count'] = $list['file_count'];
+ $data['page_size'] = $list['file_size'];
+ $data['page_biggest'] = $list['file_max'];
+ $data['page_smallest'] = $list['file_min'];
+ $data['page_nscount'] = $list['dir_count'];
+ $data['page_nsnest'] = $list['dir_nest'];
+ if($list['file_count']) $data['page_avg'] = $list['file_size'] / $list['file_count'];
+ $data['page_oldest'] = $list['file_oldest'];
+ unset($list);
+
+ // number and size of media
+ $list = array();
+ search($list,$conf['mediadir'],array($this,'_search_count'),array('all'=>true));
+ $data['media_count'] = $list['file_count'];
+ $data['media_size'] = $list['file_size'];
+ $data['media_biggest'] = $list['file_max'];
+ $data['media_smallest'] = $list['file_min'];
+ $data['media_nscount'] = $list['dir_count'];
+ $data['media_nsnest'] = $list['dir_nest'];
+ if($list['file_count']) $data['media_avg'] = $list['file_size'] / $list['file_count'];
+ unset($list);
+
+ // number and size of cache
+ $list = array();
+ search($list,$conf['cachedir'],array($this,'_search_count'),array('all'=>true));
+ $data['cache_count'] = $list['file_count'];
+ $data['cache_size'] = $list['file_size'];
+ $data['cache_biggest'] = $list['file_max'];
+ $data['cache_smallest'] = $list['file_min'];
+ if($list['file_count']) $data['cache_avg'] = $list['file_size'] / $list['file_count'];
+ unset($list);
+
+ // number and size of index
+ $list = array();
+ search($list,$conf['indexdir'],array($this,'_search_count'),array('all'=>true));
+ $data['index_count'] = $list['file_count'];
+ $data['index_size'] = $list['file_size'];
+ $data['index_biggest'] = $list['file_max'];
+ $data['index_smallest'] = $list['file_min'];
+ if($list['file_count']) $data['index_avg'] = $list['file_size'] / $list['file_count'];
+ unset($list);
+
+ // number and size of meta
+ $list = array();
+ search($list,$conf['metadir'],array($this,'_search_count'),array('all'=>true));
+ $data['meta_count'] = $list['file_count'];
+ $data['meta_size'] = $list['file_size'];
+ $data['meta_biggest'] = $list['file_max'];
+ $data['meta_smallest'] = $list['file_min'];
+ if($list['file_count']) $data['meta_avg'] = $list['file_size'] / $list['file_count'];
+ unset($list);
+
+ // number and size of attic
+ $list = array();
+ search($list,$conf['olddir'],array($this,'_search_count'),array('all'=>true));
+ $data['attic_count'] = $list['file_count'];
+ $data['attic_size'] = $list['file_size'];
+ $data['attic_biggest'] = $list['file_max'];
+ $data['attic_smallest'] = $list['file_min'];
+ if($list['file_count']) $data['attic_avg'] = $list['file_size'] / $list['file_count'];
+ $data['attic_oldest'] = $list['file_oldest'];
+ unset($list);
+
+ // user count
+ if($auth && $auth->canDo('getUserCount')){
+ $data['user_count'] = $auth->getUserCount();
+ }
+
+ // calculate edits per day
+ $list = @file($conf['metadir'].'/_dokuwiki.changes');
+ $count = count($list);
+ if($count > 2){
+ $first = (int) substr(array_shift($list),0,10);
+ $last = (int) substr(array_pop($list),0,10);
+ $dur = ($last - $first)/(60*60*24); // number of days in the changelog
+ $data['edits_per_day'] = $count/$dur;
+ }
+ unset($list);
+
+ // plugins
+ $data['plugin'] = plugin_list();
+
+ // pcre info
+ if(defined('PCRE_VERSION')) $data['pcre_version'] = PCRE_VERSION;
+ $data['pcre_backtrack'] = ini_get('pcre.backtrack_limit');
+ $data['pcre_recursion'] = ini_get('pcre.recursion_limit');
+
+ // php info
+ $data['os'] = PHP_OS;
+ $data['webserver'] = $_SERVER['SERVER_SOFTWARE'];
+ $data['php_version'] = phpversion();
+ $data['php_sapi'] = php_sapi_name();
+ $data['php_memory'] = $this->_to_byte(ini_get('memory_limit'));
+ $data['php_exectime'] = $phptime;
+ $data['php_extension'] = get_loaded_extensions();
+
+ return $data;
+ }
+
+ function _search_count(&$data,$base,$file,$type,$lvl,$opts){
+ // traverse
+ if($type == 'd'){
+ if($data['dir_nest'] < $lvl) $data['dir_nest'] = $lvl;
+ $data['dir_count']++;
+ return true;
+ }
+
+ //only search txt files if 'all' option not set
+ if($opts['all'] || substr($file,-4) == '.txt'){
+ $size = filesize($base.'/'.$file);
+ $date = filemtime($base.'/'.$file);
+ $data['file_count']++;
+ $data['file_size'] += $size;
+ if(!isset($data['file_min']) || $data['file_min'] > $size) $data['file_min'] = $size;
+ if($data['file_max'] < $size) $data['file_max'] = $size;
+ if(!isset($data['file_oldest']) || $data['file_oldest'] > $date) $data['file_oldest'] = $date;
+ }
+
+ return false;
+ }
+
+ /**
+ * Convert php.ini shorthands to byte
+ *
+ * @author <gilthans dot NO dot SPAM at gmail dot com>
+ * @link http://de3.php.net/manual/en/ini.core.php#79564
+ */
+ function _to_byte($v){
+ $l = substr($v, -1);
+ $ret = substr($v, 0, -1);
+ switch(strtoupper($l)){
+ case 'P':
+ $ret *= 1024;
+ case 'T':
+ $ret *= 1024;
+ case 'G':
+ $ret *= 1024;
+ case 'M':
+ $ret *= 1024;
+ case 'K':
+ $ret *= 1024;
+ break;
+ }
+ return $ret;
+ }
+}
diff --git a/lib/plugins/popularity/lang/ar/lang.php b/lib/plugins/popularity/lang/ar/lang.php
index c0e7dc6af..b2581294a 100644
--- a/lib/plugins/popularity/lang/ar/lang.php
+++ b/lib/plugins/popularity/lang/ar/lang.php
@@ -7,3 +7,8 @@
*/
$lang['name'] = 'رد الشعبية (قد يأخذ بعض الوقت ليحمل)';
$lang['submit'] = 'أرسل البيانات';
+$lang['autosubmit'] = 'ارسل البيانات آليا كل شهر';
+$lang['submissionFailed'] = 'تعذر إرسال البيانات بسبب الخطأ التالي:';
+$lang['submitDirectly'] = 'يمكنك إرسال البيانات يدويا بارسال النموذج التالي.';
+$lang['autosubmitError'] = 'فشلت آخر محاولة للإرسال، بسبب الخطأ التالي:';
+$lang['lastSent'] = 'أرسلت البيانات';
diff --git a/lib/plugins/popularity/lang/ar/submitted.txt b/lib/plugins/popularity/lang/ar/submitted.txt
new file mode 100644
index 000000000..085e3bd98
--- /dev/null
+++ b/lib/plugins/popularity/lang/ar/submitted.txt
@@ -0,0 +1,3 @@
+====== رد الشعبية ======
+
+أرسلت البيانات بنجاح. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/cs/intro.txt b/lib/plugins/popularity/lang/cs/intro.txt
index 70cf1a42c..4b386568a 100644
--- a/lib/plugins/popularity/lang/cs/intro.txt
+++ b/lib/plugins/popularity/lang/cs/intro.txt
@@ -1,6 +1,6 @@
===== Průzkum používání =====
-Tento nástroj jednorázově shromáží anonymní data o vaší wiki a umožní vám odeslat je vývojářům DokuWiki. To jim pomůže lépe porozumět, jak uživatelé DokuWiki používají, a jejich rozhodnutí při dalším vývoji budou založena na statistikách z reálného používání DokuWiki.
+Tento nástroj jednorázově shromáždí anonymní data o vaší wiki a umožní vám odeslat je vývojářům DokuWiki. To jim pomůže lépe porozumět, jak uživatelé DokuWiki používají, a jejich rozhodnutí při dalším vývoji budou založena na statistikách z reálného používání DokuWiki.
Chcete-li pomoci vývojářům, čas od času, jak vaše wiki poroste, použijte tento nástroj. Vaše data budou pokaždé označena stejným anonymním identifikátorem.
diff --git a/lib/plugins/popularity/lang/de-informal/lang.php b/lib/plugins/popularity/lang/de-informal/lang.php
index 076b37115..f884ed690 100644
--- a/lib/plugins/popularity/lang/de-informal/lang.php
+++ b/lib/plugins/popularity/lang/de-informal/lang.php
@@ -6,6 +6,12 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['name'] = 'Popularitätsrückmeldung (kann eine Weile dauern, bis es fertig geladen wurde)';
$lang['submit'] = 'Sende Daten';
+$lang['autosubmit'] = 'Daten einmal im Monat automatisch senden';
+$lang['submissionFailed'] = 'Die Daten konnten aufgrund des folgenden Fehlers nicht gesendet werden: ';
+$lang['submitDirectly'] = 'Du kannst die Daten durch Betätigung des Buttons manuell versenden.';
+$lang['autosubmitError'] = 'Beim letzten automatischen Versuch die Daten zu senden, ist folgender Fehler aufgetreten: ';
+$lang['lastSent'] = 'Die Daten wurden gesendet';
diff --git a/lib/plugins/popularity/lang/de-informal/submitted.txt b/lib/plugins/popularity/lang/de-informal/submitted.txt
new file mode 100644
index 000000000..e7b45b5b7
--- /dev/null
+++ b/lib/plugins/popularity/lang/de-informal/submitted.txt
@@ -0,0 +1,3 @@
+====== Popularitäts-Feedback ======
+
+Die Daten wurden erfolgreich versandt. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/de/lang.php b/lib/plugins/popularity/lang/de/lang.php
index 1372e9d8a..4649062f7 100644
--- a/lib/plugins/popularity/lang/de/lang.php
+++ b/lib/plugins/popularity/lang/de/lang.php
@@ -11,6 +11,13 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['name'] = 'Popularitäts-Feedback (Eventuell längere Ladezeit)';
$lang['submit'] = 'Daten senden';
+$lang['autosubmit'] = 'Daten einmal im Monat automatisch senden';
+$lang['submissionFailed'] = 'Die Daten konnten aufgrund des folgenden Fehlers nicht gesendet werden: ';
+$lang['submitDirectly'] = 'Sie können die Daten durch Betätigung des Buttons manuell versenden.';
+$lang['autosubmitError'] = 'Beim letzten automatischen Versuch die Daten zu senden, ist folgender Fehler aufgetreten: ';
+$lang['lastSent'] = 'Die Daten wurden gesendet';
diff --git a/lib/plugins/popularity/lang/de/submitted.txt b/lib/plugins/popularity/lang/de/submitted.txt
new file mode 100644
index 000000000..e7b45b5b7
--- /dev/null
+++ b/lib/plugins/popularity/lang/de/submitted.txt
@@ -0,0 +1,3 @@
+====== Popularitäts-Feedback ======
+
+Die Daten wurden erfolgreich versandt. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/en/lang.php b/lib/plugins/popularity/lang/en/lang.php
index c9912b7ad..78a5e862c 100644
--- a/lib/plugins/popularity/lang/en/lang.php
+++ b/lib/plugins/popularity/lang/en/lang.php
@@ -1,4 +1,9 @@
<?php
-$lang['name'] = 'Popularity Feedback (may take some time to load)';
-$lang['submit'] = 'Send Data';
+$lang['name'] = 'Popularity Feedback (may take some time to load)';
+$lang['submit'] = 'Send Data';
+$lang['autosubmit'] = 'Automatically send data once a month';
+$lang['submissionFailed'] = 'The data couldn\'t be sent due to the following error:';
+$lang['submitDirectly'] = 'You can send the data manually by submitting the following form.';
+$lang['autosubmitError'] = 'The last autosubmit failed, because of the following error: ';
+$lang['lastSent'] = 'The data has been sent ';
diff --git a/lib/plugins/popularity/lang/en/submitted.txt b/lib/plugins/popularity/lang/en/submitted.txt
new file mode 100644
index 000000000..30f2784aa
--- /dev/null
+++ b/lib/plugins/popularity/lang/en/submitted.txt
@@ -0,0 +1,3 @@
+====== Popularity Feedback ======
+
+The data has been sent succesfully.
diff --git a/lib/plugins/popularity/lang/es/lang.php b/lib/plugins/popularity/lang/es/lang.php
index c76190c2c..6aa9a823d 100644
--- a/lib/plugins/popularity/lang/es/lang.php
+++ b/lib/plugins/popularity/lang/es/lang.php
@@ -19,3 +19,8 @@
*/
$lang['name'] = 'Retroinformación (Feedback) plugin Popularity';
$lang['submit'] = 'Enviar datos';
+$lang['autosubmit'] = 'Enviar automáticamente datos una vez al mes';
+$lang['submissionFailed'] = 'Los datos no se pudo enviar debido al error siguiente:';
+$lang['submitDirectly'] = 'Puede enviar los datos de forma manual mediante la presentación de la siguiente forma.';
+$lang['autosubmitError'] = 'El último auto no pudo presentar, debido al error siguiente:';
+$lang['lastSent'] = 'Los datos se han enviado';
diff --git a/lib/plugins/popularity/lang/es/submitted.txt b/lib/plugins/popularity/lang/es/submitted.txt
new file mode 100644
index 000000000..bb1754cdd
--- /dev/null
+++ b/lib/plugins/popularity/lang/es/submitted.txt
@@ -0,0 +1,3 @@
+====== Retroinformación Popularity ======
+
+Los datos se han enviado con éxito. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/he/lang.php b/lib/plugins/popularity/lang/he/lang.php
index 024f94ae8..f619127cd 100644
--- a/lib/plugins/popularity/lang/he/lang.php
+++ b/lib/plugins/popularity/lang/he/lang.php
@@ -5,6 +5,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['name'] = 'משוב פופולריות (יתכן זמן טעינה ארוך)';
$lang['submit'] = 'שלח מידע';
diff --git a/lib/plugins/popularity/lang/ko/lang.php b/lib/plugins/popularity/lang/ko/lang.php
index 3a28b1b0e..91d798a5f 100644
--- a/lib/plugins/popularity/lang/ko/lang.php
+++ b/lib/plugins/popularity/lang/ko/lang.php
@@ -6,6 +6,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['name'] = '인기도 조사 (불러오는데 시간이 걸릴 수 있습니다.)';
$lang['submit'] = '자료 보내기';
diff --git a/lib/plugins/popularity/lang/la/intro.txt b/lib/plugins/popularity/lang/la/intro.txt
index 6f4ce8488..c3029caf4 100644
--- a/lib/plugins/popularity/lang/la/intro.txt
+++ b/lib/plugins/popularity/lang/la/intro.txt
@@ -1,5 +1,10 @@
====== Index Fauoris Popularis ======
-Haec machina fauorem popularem mittis sic ut creatores uicis meliorem illum facere possint.
+Haoc instrumentum fauorem popularem mittis sic ut creatores uicis meliorem illum facere possint.
+
+Rursum te fauorem mittere experamus sic ut si mutationes meliores uel peiores esse uidere possimus.
+
+Res mittendae tua forma in usu, numerus et pondus paginarum et aliarum rerum, addenda in usu et de PHP.
+
+Res rudes mittendae subter ostenduntur. "Res mittere" premas ut eas transferas.
-Rursum te fauorem mittere experamus sic ut si mutationes meliores uel peiores esse uidere possimus. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/la/lang.php b/lib/plugins/popularity/lang/la/lang.php
index e634f9d41..c7f307c29 100644
--- a/lib/plugins/popularity/lang/la/lang.php
+++ b/lib/plugins/popularity/lang/la/lang.php
@@ -2,6 +2,12 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
$lang['name'] = 'Index fauoris popularis (multum tempus quaerere potest)';
$lang['submit'] = 'Missum die';
+$lang['autosubmit'] = 'Constanter res omni mense mittuntur';
+$lang['submissionFailed'] = 'Res non mittuntur ea causa:';
+$lang['submitDirectly'] = 'Res tu mittere potes cum hoc exemplar compleas.';
+$lang['autosubmitError'] = 'Extrema missio lapsa est ea causa:';
+$lang['lastSent'] = 'Res missae sunt';
diff --git a/lib/plugins/popularity/lang/la/submitted.txt b/lib/plugins/popularity/lang/la/submitted.txt
new file mode 100644
index 000000000..2b2faf439
--- /dev/null
+++ b/lib/plugins/popularity/lang/la/submitted.txt
@@ -0,0 +1,3 @@
+====== Index fauoris popularis ======
+
+Res feliciter missae sunt. \ No newline at end of file
diff --git a/lib/plugins/popularity/lang/ru/intro.txt b/lib/plugins/popularity/lang/ru/intro.txt
index 587a7ae85..e8118e4eb 100644
--- a/lib/plugins/popularity/lang/ru/intro.txt
+++ b/lib/plugins/popularity/lang/ru/intro.txt
@@ -1,10 +1,10 @@
====== Сбор информации о популярности ======
-Этот инструмент собирает анонимные данные о вашей вики и позволяет вам отправить их разработчикам «ДокуВики». Эти данные помогут им понять то, как именно используется «ДокуВики», и удостовериться, что принимаемые проектные решения соответствуют жизненным реалиям.
+Этот инструмент собирает анонимные данные о вашей вики и позволяет вам отправить их разработчикам «ДокуВики». Эти данные помогут им понять, как именно используется «ДокуВики», и удостовериться, что принимаемые проектные решения соответствуют жизненным реалиям.
-Отправляйте данные время от времени для того, чтобы сообщить разработчикам о том, что ваша вики «подросла». Отправленные вами данные будут идентифицированы по анонимному ID.
+Отправляйте данные время от времени для того, чтобы сообщать разработчикам о том, что ваша вики «подросла». Отправленные вами данные будут идентифицированы по анонимному ID.
Собранные данные содержат такую информацию, как: версия «ДокуВики», количество и размер ваших страниц и файлов, установленные плагины, информацию об установленном PHP.
-Данные, которые будут посланы, представлены ниже. Пожалуйста, используйте кнопку «Отправить данные», чтобы передать информацию.
+Данные, которые будут отосланы, представлены ниже. Пожалуйста, используйте кнопку «Отправить данные», чтобы передать информацию.
diff --git a/lib/plugins/popularity/lang/ru/lang.php b/lib/plugins/popularity/lang/ru/lang.php
index df89c7022..b63558134 100644
--- a/lib/plugins/popularity/lang/ru/lang.php
+++ b/lib/plugins/popularity/lang/ru/lang.php
@@ -14,3 +14,8 @@
*/
$lang['name'] = 'Сбор информации о популярности (для загрузки может потребоваться некоторое время)';
$lang['submit'] = 'Отправить данные';
+$lang['autosubmit'] = 'Автоматически отправлять данные один раз в месяц';
+$lang['submissionFailed'] = 'Данные не могут быть отправлены из-за ошибки:';
+$lang['submitDirectly'] = 'Вы можете отправлять данные вручную, заполнив форму:';
+$lang['autosubmitError'] = 'Последнее автоотправление данных не удалось из-за ошибки:';
+$lang['lastSent'] = 'Данные отправлены';
diff --git a/lib/plugins/popularity/lang/sl/lang.php b/lib/plugins/popularity/lang/sl/lang.php
index befb1eec0..dc81ec060 100644
--- a/lib/plugins/popularity/lang/sl/lang.php
+++ b/lib/plugins/popularity/lang/sl/lang.php
@@ -4,5 +4,6 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
$lang['submit'] = 'Pošlji';
diff --git a/lib/plugins/popularity/lang/tr/lang.php b/lib/plugins/popularity/lang/tr/lang.php
index 682b51218..fe87d1548 100644
--- a/lib/plugins/popularity/lang/tr/lang.php
+++ b/lib/plugins/popularity/lang/tr/lang.php
@@ -2,11 +2,10 @@
/**
* Turkish language file
*
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['name'] = 'Popülerlik Geribeslemesi (yüklemesi uzun sürebilir)';
$lang['submit'] = 'Verileri Gönder';
diff --git a/lib/plugins/popularity/plugin.info.txt b/lib/plugins/popularity/plugin.info.txt
new file mode 100644
index 000000000..2652bd669
--- /dev/null
+++ b/lib/plugins/popularity/plugin.info.txt
@@ -0,0 +1,7 @@
+base popularity
+author Andreas Gohr
+email andi@splitbrain.org
+date 2010-12-09
+name Popularity Feedback Plugin
+desc Send anonymous data about your wiki to the developers.
+url http://www.dokuwiki.org/plugin:popularity
diff --git a/lib/plugins/revert/admin.php b/lib/plugins/revert/admin.php
index 8a2cd5553..e188e2488 100644
--- a/lib/plugins/revert/admin.php
+++ b/lib/plugins/revert/admin.php
@@ -196,4 +196,4 @@ class admin_plugin_revert extends DokuWiki_Admin_Plugin {
}
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/revert/lang/cs/intro.txt b/lib/plugins/revert/lang/cs/intro.txt
index bbc0df25a..1e1cd0fd8 100644
--- a/lib/plugins/revert/lang/cs/intro.txt
+++ b/lib/plugins/revert/lang/cs/intro.txt
@@ -1,3 +1,3 @@
====== Obnova zaspamovaných stránek ======
-Tato stránka pomůže při automatické obnově po spamovém útoku. Pro nalezení seznamu zaspamovaných stránek nedřív zadejte hledaný výraz (např. spamové URL) a pak potvrďte, že nalezené stránky opravdu obsahují spam a mohou být obnoveny.
+Tato stránka pomůže při automatické obnově po spamovém útoku. Pro nalezení seznamu zaspamovaných stránek nejdříve zadejte hledaný výraz (např. spamové URL) a pak potvrďte, že nalezené stránky opravdu obsahují spam a mohou být obnoveny.
diff --git a/lib/plugins/revert/lang/de-informal/lang.php b/lib/plugins/revert/lang/de-informal/lang.php
index ac2f35e85..b6709d2fa 100644
--- a/lib/plugins/revert/lang/de-informal/lang.php
+++ b/lib/plugins/revert/lang/de-informal/lang.php
@@ -6,6 +6,7 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Zurückstellungsmanager';
$lang['filter'] = 'Durchsuche als Spam markierte Seiten';
diff --git a/lib/plugins/revert/lang/de/lang.php b/lib/plugins/revert/lang/de/lang.php
index 5dee8007b..0bc8e2ce0 100644
--- a/lib/plugins/revert/lang/de/lang.php
+++ b/lib/plugins/revert/lang/de/lang.php
@@ -12,6 +12,8 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Seiten wieder herstellen';
$lang['filter'] = 'Nach betroffenen Seiten suchen';
diff --git a/lib/plugins/revert/lang/en/lang.php b/lib/plugins/revert/lang/en/lang.php
index a2002f1a7..6bf867ded 100644
--- a/lib/plugins/revert/lang/en/lang.php
+++ b/lib/plugins/revert/lang/en/lang.php
@@ -20,4 +20,4 @@ $lang['revstop'] = 'Reversion process finished successfully.';
$lang['note1'] = 'Note: this search is case sensitive';
$lang['note2'] = 'Note: the page will be reverted to the last version not containing the given spam term <i>%s</i>.';
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/revert/lang/he/lang.php b/lib/plugins/revert/lang/he/lang.php
index 585487816..ac3c3412e 100644
--- a/lib/plugins/revert/lang/he/lang.php
+++ b/lib/plugins/revert/lang/he/lang.php
@@ -5,6 +5,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['menu'] = 'מנהל שחזור';
$lang['filter'] = 'חפש דפים עם ספאם';
diff --git a/lib/plugins/revert/lang/ko/lang.php b/lib/plugins/revert/lang/ko/lang.php
index 5e070de92..0163d2754 100644
--- a/lib/plugins/revert/lang/ko/lang.php
+++ b/lib/plugins/revert/lang/ko/lang.php
@@ -6,6 +6,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['menu'] = '복구 관리자';
$lang['filter'] = '스팸 페이지 검색 ';
diff --git a/lib/plugins/revert/lang/la/intro.txt b/lib/plugins/revert/lang/la/intro.txt
index 35916f683..99a206f63 100644
--- a/lib/plugins/revert/lang/la/intro.txt
+++ b/lib/plugins/revert/lang/la/intro.txt
@@ -1,3 +1,3 @@
====== Restituendi Administrator ======
-Haec pagina contra mala interretialia paginas restituta. Ut paginas aegras quaeras, malum VRL scribe, deinde paginas malas eligas. \ No newline at end of file
+Haec pagina contra mala interretialia paginas restituta. Vt paginas aegras quaeras, malum VRL scribe, deinde paginas malas eligas. \ No newline at end of file
diff --git a/lib/plugins/revert/lang/la/lang.php b/lib/plugins/revert/lang/la/lang.php
index f742e63f2..af4203437 100644
--- a/lib/plugins/revert/lang/la/lang.php
+++ b/lib/plugins/revert/lang/la/lang.php
@@ -2,6 +2,7 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
$lang['menu'] = 'Restituendi administrator';
$lang['filter'] = 'Malas paginas quaerere';
diff --git a/lib/plugins/revert/lang/ru/intro.txt b/lib/plugins/revert/lang/ru/intro.txt
index 66c5af005..52d1f8d3d 100644
--- a/lib/plugins/revert/lang/ru/intro.txt
+++ b/lib/plugins/revert/lang/ru/intro.txt
@@ -1,3 +1,3 @@
====== Менеджер откаток ======
-Эта страница поможет вам в автоматической откатке изменений после спам-атаки. Для того, чтобы найти спам-страницы, введите ключевые слова и произведите поиск (например, по URL спамера). Затем убедитесь, что найденные страницы действительно содержат спам, и сделайте откатку изменений.
+Эта страница поможет вам в автоматической откатке изменений после спам-атаки. Для того, чтобы найти спам-страницы, введите ключевые слова и произведите поиск (например, по URL спамера). Затем убедитесь, что найденные страницы действительно содержат спам и сделайте откатку изменений.
diff --git a/lib/plugins/revert/lang/sl/lang.php b/lib/plugins/revert/lang/sl/lang.php
index 1fcf4ca36..57ae9d092 100644
--- a/lib/plugins/revert/lang/sl/lang.php
+++ b/lib/plugins/revert/lang/sl/lang.php
@@ -4,4 +4,5 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
diff --git a/lib/plugins/revert/lang/tr/lang.php b/lib/plugins/revert/lang/tr/lang.php
index 164a8ec4f..aa1458a95 100644
--- a/lib/plugins/revert/lang/tr/lang.php
+++ b/lib/plugins/revert/lang/tr/lang.php
@@ -2,11 +2,10 @@
/**
* Turkish language file
*
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['menu'] = 'Eskiye Döndürme';
$lang['filter'] = 'Spam bulunan sayfaları ara';
diff --git a/lib/plugins/syntax.php b/lib/plugins/syntax.php
index 127b92ce5..12451f636 100644
--- a/lib/plugins/syntax.php
+++ b/lib/plugins/syntax.php
@@ -188,10 +188,13 @@ class DokuWiki_Syntax_Plugin extends Doku_Parser_Mode {
function localFN($id) {
global $conf;
$plugin = $this->getPluginName();
- $file = DOKU_PLUGIN.$plugin.'/lang/'.$conf['lang'].'/'.$id.'.txt';
- if(!@file_exists($file)){
- //fall back to english
- $file = DOKU_PLUGIN.$plugin.'/lang/en/'.$id.'.txt';
+ $file = DOKU_CONF.'/plugin_lang/'.$plugin.'/'.$conf['lang'].'/'.$id.'.txt';
+ if (!@file_exists($file)){
+ $file = DOKU_PLUGIN.$plugin.'/lang/'.$conf['lang'].'/'.$id.'.txt';
+ if(!@file_exists($file)){
+ //fall back to english
+ $file = DOKU_PLUGIN.$plugin.'/lang/en/'.$id.'.txt';
+ }
}
return $file;
}
@@ -276,4 +279,4 @@ class DokuWiki_Syntax_Plugin extends Doku_Parser_Mode {
}
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :
diff --git a/lib/plugins/usermanager/lang/cs/lang.php b/lib/plugins/usermanager/lang/cs/lang.php
index 9c5a2abc9..7d8e4599d 100644
--- a/lib/plugins/usermanager/lang/cs/lang.php
+++ b/lib/plugins/usermanager/lang/cs/lang.php
@@ -45,7 +45,7 @@ $lang['edit_usermissing'] = 'Vybraný uživatel nebyl nalezen, zadané uži
$lang['user_notify'] = 'Upozornit uživatele';
$lang['note_notify'] = 'Maily s upozorněním se budou posílat pouze, když uživatel dostává nové heslo.';
$lang['note_group'] = 'Noví uživatelé budou přidáváni do této výchozí skupiny (%s), pokud pro ně není uvedena žádná skupina.';
-$lang['note_pass'] = 'Heslo bude automaticky vygenerováno pokud je pole ponacháno prázdné a je zapnutá notifikace uživatele.';
+$lang['note_pass'] = 'Heslo bude automaticky vygenerováno pokud je pole ponecháno prázdné a je zapnutá notifikace uživatele.';
$lang['add_ok'] = 'Uživatel úspěšně vytvořen';
$lang['add_fail'] = 'Vytvoření uživatele selhalo';
$lang['notify_ok'] = 'Odeslán mail s upozorněním';
diff --git a/lib/plugins/usermanager/lang/de-informal/lang.php b/lib/plugins/usermanager/lang/de-informal/lang.php
index e906c0cf8..95b36c60f 100644
--- a/lib/plugins/usermanager/lang/de-informal/lang.php
+++ b/lib/plugins/usermanager/lang/de-informal/lang.php
@@ -6,6 +6,7 @@
* @author Juergen Schwarzer <jschwarzer@freenet.de>
* @author Marcel Metz <marcel_metz@gmx.de>
* @author Matthias Schulte <post@lupo49.de>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Benutzerverwalter';
$lang['noauth'] = '(Benutzeranmeldung ist nicht verfügbar)';
diff --git a/lib/plugins/usermanager/lang/de/lang.php b/lib/plugins/usermanager/lang/de/lang.php
index 816aaebd7..090d1d1d9 100644
--- a/lib/plugins/usermanager/lang/de/lang.php
+++ b/lib/plugins/usermanager/lang/de/lang.php
@@ -13,6 +13,8 @@
* @author Blitzi94@gmx.de
* @author Robert Bogenschneider <robog@GMX.de>
* @author Robert Bogenschneider <robog@gmx.de>
+ * @author Niels Lange <niels@boldencursief.nl>
+ * @author Christian Wichmann <nospam@zone0.de>
*/
$lang['menu'] = 'Benutzerverwaltung';
$lang['noauth'] = '(Authentifizierungssystem nicht verfügbar)';
diff --git a/lib/plugins/usermanager/lang/he/lang.php b/lib/plugins/usermanager/lang/he/lang.php
index b2b55c3b4..601163013 100644
--- a/lib/plugins/usermanager/lang/he/lang.php
+++ b/lib/plugins/usermanager/lang/he/lang.php
@@ -6,6 +6,7 @@
* @author Dotan Kamber <kamberd@yahoo.com>
* @author Moshe Kaplan <mokplan@gmail.com>
* @author Yaron Yogev <yaronyogev@gmail.com>
+ * @author Yaron Shahrabani <sh.yaron@gmail.com>
*/
$lang['menu'] = 'מנהל משתמשים';
$lang['noauth'] = '(אימות משתמשים אינו זמין)';
diff --git a/lib/plugins/usermanager/lang/ko/lang.php b/lib/plugins/usermanager/lang/ko/lang.php
index eeb8eb791..f2322414a 100644
--- a/lib/plugins/usermanager/lang/ko/lang.php
+++ b/lib/plugins/usermanager/lang/ko/lang.php
@@ -6,6 +6,7 @@
* @author dongnak@gmail.com
* @author Song Younghwan <purluno@gmail.com>
* @author SONG Younghwan <purluno@gmail.com>
+ * @author Seung-Chul Yoo <dryoo@live.com>
*/
$lang['menu'] = '사용자 관리자';
$lang['noauth'] = '(사용자 인증이 불가능합니다.)';
diff --git a/lib/plugins/usermanager/lang/la/lang.php b/lib/plugins/usermanager/lang/la/lang.php
index 2646979bd..52c848754 100644
--- a/lib/plugins/usermanager/lang/la/lang.php
+++ b/lib/plugins/usermanager/lang/la/lang.php
@@ -2,6 +2,7 @@
/**
* Latin language file
*
+ * @author Massimiliano Vassalli <vassalli.max@gmail.com>
*/
$lang['menu'] = 'Sodalis Tabella';
$lang['noauth'] = '(Sodalis confirmatio deest)';
diff --git a/lib/plugins/usermanager/lang/ru/lang.php b/lib/plugins/usermanager/lang/ru/lang.php
index 81d9a72a6..d7a0591ab 100644
--- a/lib/plugins/usermanager/lang/ru/lang.php
+++ b/lib/plugins/usermanager/lang/ru/lang.php
@@ -47,12 +47,12 @@ $lang['start'] = 'в начало';
$lang['prev'] = 'назад';
$lang['next'] = 'вперёд';
$lang['last'] = 'в конец';
-$lang['edit_usermissing'] = 'Выбранный пользователь не найден. Возможно, указанный логин был удалён или изменен извне.';
+$lang['edit_usermissing'] = 'Выбранный пользователь не найден. Возможно, указанный логин был удалён или изменён извне.';
$lang['user_notify'] = 'Сообщить пользователю';
$lang['note_notify'] = 'Письма с уведомлением высылаются только в случае получения нового пароля.';
$lang['note_group'] = 'Если группа не указана, новые пользователи будут добавлены в группу по умолчанию (%s).';
$lang['note_pass'] = 'Пароль будет сгенерирован автоматически, если поле оставлено пустым и включено уведомление пользователя.';
$lang['add_ok'] = 'Пользователь успешно добавлен';
$lang['add_fail'] = 'Не удалось добавить пользователя';
-$lang['notify_ok'] = 'Пиьмо с уведомлением отправлено';
+$lang['notify_ok'] = 'Письмо с уведомлением отправлено';
$lang['notify_fail'] = 'Не удалось отправить письмо с уведомлением';
diff --git a/lib/plugins/usermanager/lang/sl/lang.php b/lib/plugins/usermanager/lang/sl/lang.php
index e31f8ff1a..b671d65dc 100644
--- a/lib/plugins/usermanager/lang/sl/lang.php
+++ b/lib/plugins/usermanager/lang/sl/lang.php
@@ -4,17 +4,35 @@
*
* @author Dejan Levec <webphp@gmail.com>
* @author Boštjan Seničar <senicar@gmail.com>
+ * @author Gregor Skumavc (grega.skumavc@gmail.com)
*/
+$lang['menu'] = 'Urejanje uporabnikov';
+$lang['noauth'] = '(preverjanje uporabnikov ni na voljo)';
+$lang['nosupport'] = '(urejanje uporabnikov ni podprto)';
+$lang['badauth'] = 'neeljaven mehanizem za preverjanje';
$lang['user_id'] = 'Uporabnik';
$lang['user_pass'] = 'Geslo';
+$lang['user_name'] = 'Pravo ime';
$lang['user_mail'] = 'Email';
$lang['user_groups'] = 'Skupine';
+$lang['field'] = 'Polje';
+$lang['value'] = 'Vrednost';
$lang['add'] = 'Dodaj';
$lang['delete'] = 'Izbriši';
$lang['delete_selected'] = 'Izbriši izbrano';
$lang['edit'] = 'Uredi';
+$lang['edit_prompt'] = 'Uredi tega uporabnika';
$lang['modify'] = 'Shrani spremembe';
$lang['search'] = 'Iskanje';
+$lang['search_prompt'] = 'Išči';
+$lang['clear'] = 'Ponastavi filter iskanja';
+$lang['filter'] = 'Filter';
+$lang['summary'] = 'Prikazujem uporabnike %1$d-%2$d od najdenih %3$d. Vseh je %4$d.';
+$lang['nonefound'] = 'Ni najdenih uporabnikov. Vseh uporabnikov je %d.';
+$lang['delete_ok'] = '%d uporabnikov izbrisanih';
+$lang['delete_fail'] = '%d ni bilo možno izbrisati';
+$lang['update_ok'] = 'Uporabnik uspešno posodobljen';
+$lang['update_fail'] = 'Posodobitev uporabnika ni uspela';
$lang['prev'] = 'Prejšnji';
$lang['next'] = 'Naslednji';
$lang['last'] = 'Zadnji';
diff --git a/lib/plugins/usermanager/lang/tr/lang.php b/lib/plugins/usermanager/lang/tr/lang.php
index 28127d9d0..b9c9cfc52 100644
--- a/lib/plugins/usermanager/lang/tr/lang.php
+++ b/lib/plugins/usermanager/lang/tr/lang.php
@@ -2,11 +2,10 @@
/**
* Turkish language file
*
- * @author Aydın Coşkuner aydinweb@gmail.com
* @author Aydın Coşkuner <aydinweb@gmail.com>
- * @author yavuzselim@gmail.com
- * @author Cihan Kahveci kahvecicihan@gmail.com
+ * @author Cihan Kahveci <kahvecicihan@gmail.com>
* @author Yavuz Selim <yavuzselim@gmail.com>
+ * @author Caleb Maclennan <caleb@alerque.com>
*/
$lang['menu'] = 'Kullanıcı Yönetimi';
$lang['noauth'] = '(kullanıcı onaylaması yoktur)';
diff --git a/lib/scripts/ajax.js b/lib/scripts/ajax.js
index de009d448..44dcee999 100644
--- a/lib/scripts/ajax.js
+++ b/lib/scripts/ajax.js
@@ -5,44 +5,114 @@
* @author Andreas Gohr <andi@splitbrain.org>
* @author Adrian Lang <lang@cosmocode.de>
*/
-addInitEvent(function () {
+var ajax_quicksearch = {
- var inID = 'qsearch__in';
- var outID = 'qsearch__out';
+ inObj: null,
+ outObj: null,
+ sackObj: null,
+ delay: null,
- var inObj = document.getElementById(inID);
- var outObj = document.getElementById(outID);
+ init: function(inID, outID) {
- // objects found?
- if (inObj === null){ return; }
- if (outObj === null){ return; }
+ this.inObj = $(inID);
+ this.outObj = $(outID);
- function clear_results(){
- outObj.style.display = 'none';
- outObj.innerHTML = '';
- }
+ // objects found?
+ if (this.inObj === null) return;
+ if (this.outObj === null) return;
+
+ // prepare AJAX
+ this.sackObj = new sack(DOKU_BASE + 'lib/exe/ajax.php');
+ this.sackObj.AjaxFailedAlert = '';
+ this.sackObj.encodeURIString = false;
+ this.sackObj.onCompletion = ajax_quicksearch.onCompletion;
+
+ // attach eventhandler to search field
+ this.delay = new Delay(function () {
+ ajax_quicksearch.clear_results();
+ var value = ajax_quicksearch.inObj.value;
+ if(value === ''){ return; }
+ ajax_quicksearch.sackObj.runAJAX('call=qsearch&q=' + encodeURI(value));
+ });
+
+ addEvent(this.inObj, 'keyup', function () {
+ ajax_quicksearch.clear_results();
+ ajax_quicksearch.delay.start();
+ });
- var sack_obj = new sack(DOKU_BASE + 'lib/exe/ajax.php');
- sack_obj.AjaxFailedAlert = '';
- sack_obj.encodeURIString = false;
- sack_obj.onCompletion = function () {
- var data = sack_obj.response;
+ // attach eventhandler to output field
+ addEvent(this.outObj, 'click', function () {
+ ajax_quicksearch.outObj.style.display = 'none';
+ });
+ },
+
+ clear_results: function(){
+ ajax_quicksearch.outObj.style.display = 'none';
+ ajax_quicksearch.outObj.innerHTML = '';
+ },
+
+ onCompletion: function() {
+ var data = this.response; // 'this' is sack context
if (data === '') { return; }
+ var outObj = ajax_quicksearch.outObj;
+
outObj.innerHTML = data;
outObj.style.display = 'block';
- };
+ outObj.style['white-space'] = 'nowrap';
- // attach eventhandler to search field
- var delay = new Delay(function () {
- clear_results();
- var value = inObj.value;
- if(value === ''){ return; }
- sack_obj.runAJAX('call=qsearch&q=' + encodeURI(value));
- });
+ // shorten namespaces if too long
+ var width = outObj.clientWidth;
+ var links = outObj.getElementsByTagName('a');
+ for(var i=0; i<links.length; i++){
+ // maximum allowed width:
+ var max = width - links[i].offsetLeft;
+ var isRTL = (document.documentElement.dir == 'rtl');
- addEvent(inObj, 'keyup', function () {clear_results(); delay.start(); });
+ if(!isRTL && links[i].offsetWidth < max) continue;
+ if(isRTL && links[i].offsetLeft > 0) continue;
- // attach eventhandler to output field
- addEvent(outObj, 'click', function () {outObj.style.display = 'none'; });
+ var nsL = links[i].innerText.indexOf('(');
+ var nsR = links[i].innerText.indexOf(')');
+ var eli = 0;
+ var runaway = 0;
+
+ while( (nsR - nsL > 3) &&
+ (
+ (!isRTL && links[i].offsetWidth > max) ||
+ (isRTL && links[i].offsetLeft < 0)
+ )
+ ){
+ if(runaway++ > 500) return; // just in case something went wrong
+
+ if(eli){
+ // elipsis already inserted
+ if( (eli - nsL) > (nsR - eli) ){
+ // cut left
+ links[i].innerText = links[i].innerText.substring(0,eli-2)+
+ links[i].innerText.substring(eli);
+ }else{
+ // cut right
+ links[i].innerText = links[i].innerText.substring(0,eli+1)+
+ links[i].innerText.substring(eli+2);
+ }
+ }else{
+ // replace middle with ellipsis
+ var mid = Math.floor( nsL + ((nsR-nsL)/2) );
+ links[i].innerText = links[i].innerText.substring(0,mid)+'…'+
+ links[i].innerText.substring(mid+1);
+ }
+ eli = links[i].innerText.indexOf('…');
+ nsL = links[i].innerText.indexOf('(');
+ nsR = links[i].innerText.indexOf(')');
+ }
+ }
+ }
+
+};
+
+
+addInitEvent(function(){
+ ajax_quicksearch.init('qsearch__in','qsearch__out');
});
+
diff --git a/lib/tpl/default/rtl.css b/lib/tpl/default/rtl.css
index e40dd966d..82c85839b 100644
--- a/lib/tpl/default/rtl.css
+++ b/lib/tpl/default/rtl.css
@@ -55,8 +55,7 @@ div.dokuwiki li ol {
div.dokuwiki a.urlextern,
div.dokuwiki a.interwiki,
div.dokuwiki a.windows,
-div.dokuwiki a.mail,
-div.dokuwiki a.mail.JSnocheck {
+div.dokuwiki a.mail {
/* should work but doesn't - so we just disable icons here*/
/*
background-position: right 1px;