diff options
Diffstat (limited to 'lib')
28 files changed, 348 insertions, 29 deletions
diff --git a/lib/exe/indexer.php b/lib/exe/indexer.php index 330b8498d..d2a4d45f7 100644 --- a/lib/exe/indexer.php +++ b/lib/exe/indexer.php @@ -199,7 +199,7 @@ function sendGIF(){ header('Content-Length: '.strlen($img)); header('Connection: Close'); print $img; - flush(); + tpl_flush(); // Browser should drop connection after this // Thinks it's got the whole image } diff --git a/lib/exe/js.php b/lib/exe/js.php index 3f9781e34..06d0dda55 100644 --- a/lib/exe/js.php +++ b/lib/exe/js.php @@ -14,7 +14,7 @@ require_once(DOKU_INC.'inc/init.php'); // Main (don't run when UNIT test) if(!defined('SIMPLE_TEST')){ - header('Content-Type: text/javascript; charset=utf-8'); + header('Content-Type: application/javascript; charset=utf-8'); js_out(); } diff --git a/lib/images/interwiki/tel.gif b/lib/images/interwiki/tel.gif Binary files differnew file mode 100644 index 000000000..60158c565 --- /dev/null +++ b/lib/images/interwiki/tel.gif diff --git a/lib/plugins/acl/remote.php b/lib/plugins/acl/remote.php index b10c544ee..42449428f 100644 --- a/lib/plugins/acl/remote.php +++ b/lib/plugins/acl/remote.php @@ -32,9 +32,14 @@ class remote_plugin_acl extends DokuWiki_Remote_Plugin { * @param string $scope * @param string $user * @param int $level see also inc/auth.php + * @throws RemoteAccessDeniedException * @return bool */ public function addAcl($scope, $user, $level){ + if(!auth_isadmin()) { + throw new RemoteAccessDeniedException('You are not allowed to access ACLs, superuser permission is required', 114); + } + /** @var admin_plugin_acl $apa */ $apa = plugin_load('admin', 'acl'); return $apa->_acl_add($scope, $user, $level); @@ -45,9 +50,14 @@ class remote_plugin_acl extends DokuWiki_Remote_Plugin { * * @param string $scope * @param string $user + * @throws RemoteAccessDeniedException * @return bool */ public function delAcl($scope, $user){ + if(!auth_isadmin()) { + throw new RemoteAccessDeniedException('You are not allowed to access ACLs, superuser permission is required', 114); + } + /** @var admin_plugin_acl $apa */ $apa = plugin_load('admin', 'acl'); return $apa->_acl_del($scope, $user); diff --git a/lib/plugins/authad/auth.php b/lib/plugins/authad/auth.php index 88b56046c..400a5efee 100644 --- a/lib/plugins/authad/auth.php +++ b/lib/plugins/authad/auth.php @@ -3,6 +3,7 @@ if(!defined('DOKU_INC')) die(); require_once(DOKU_PLUGIN.'authad/adLDAP/adLDAP.php'); +require_once(DOKU_PLUGIN.'authad/adLDAP/classes/adLDAPUtils.php'); /** * Active Directory authentication backend for DokuWiki @@ -67,6 +68,10 @@ class auth_plugin_authad extends DokuWiki_Auth_Plugin { */ protected $_pattern = array(); + protected $_actualstart = 0; + + protected $_grpsusers = array(); + /** * Constructor */ @@ -116,6 +121,7 @@ class auth_plugin_authad extends DokuWiki_Auth_Plugin { // other can do's are changed in $this->_loadServerConfig() base on domain setup $this->cando['modName'] = true; $this->cando['modMail'] = true; + $this->cando['getUserCount'] = true; } /** @@ -326,14 +332,137 @@ class auth_plugin_authad extends DokuWiki_Auth_Plugin { } /** + * Create a Search-String useable by adLDAPUsers::all($includeDescription = false, $search = "*", $sorted = true) + * + * @param array $filter + * @return string + */ + protected function _constructSearchString($filter){ + if (!$filter){ + return '*'; + } + $adldapUtils = new adLDAPUtils($this->_adldap(null)); + $result = '*'; + if (isset($filter['name'])) { + $result .= ')(displayname=*' . $adldapUtils->ldapSlashes($filter['name']) . '*'; + unset($filter['name']); + } + + if (isset($filter['user'])) { + $result .= ')(samAccountName=*' . $adldapUtils->ldapSlashes($filter['user']) . '*'; + unset($filter['user']); + } + + if (isset($filter['mail'])) { + $result .= ')(mail=*' . $adldapUtils->ldapSlashes($filter['mail']) . '*'; + unset($filter['mail']); + } + return $result; + } + + /** + * Return a count of the number of user which meet $filter criteria + * + * @param array $filter $filter array of field/pattern pairs, empty array for no filter + * @return int number of users + */ + public function getUserCount($filter = array()) { + $adldap = $this->_adldap(null); + if(!$adldap) { + dbglog("authad/auth.php getUserCount(): _adldap not set."); + return -1; + } + if ($filter == array()) { + $result = $adldap->user()->all(); + } else { + $searchString = $this->_constructSearchString($filter); + $result = $adldap->user()->all(false, $searchString); + if (isset($filter['grps'])) { + $this->users = array_fill_keys($result, false); + $usermanager = plugin_load("admin", "usermanager", false); + $usermanager->setLastdisabled(true); + if (!isset($this->_grpsusers[$this->_filterToString($filter)])){ + $this->_fillGroupUserArray($filter,$usermanager->getStart() + 3*$usermanager->getPagesize()); + } elseif (count($this->_grpsusers[$this->_filterToString($filter)]) < $usermanager->getStart() + 3*$usermanager->getPagesize()) { + $this->_fillGroupUserArray($filter,$usermanager->getStart() + 3*$usermanager->getPagesize() - count($this->_grpsusers[$this->_filterToString($filter)])); + } + $result = $this->_grpsusers[$this->_filterToString($filter)]; + } else { + $usermanager = plugin_load("admin", "usermanager", false); + $usermanager->setLastdisabled(false); + } + + } + + if (!$result) { + return 0; + } + return count($result); + } + + /** + * + * create a unique string for each filter used with a group + * + * @param array $filter + * @return string + */ + protected function _filterToString ($filter) { + $result = ''; + if (isset($filter['user'])) { + $result .= 'user-' . $filter['user']; + } + if (isset($filter['name'])) { + $result .= 'name-' . $filter['name']; + } + if (isset($filter['mail'])) { + $result .= 'mail-' . $filter['mail']; + } + if (isset($filter['grps'])) { + $result .= 'grps-' . $filter['grps']; + } + return $result; + } + + /** + * Create an array of $numberOfAdds users passing a certain $filter, including belonging + * to a certain group and save them to a object-wide array. If the array + * already exists try to add $numberOfAdds further users to it. + * + * @param array $filter + * @param int $numberOfAdds additional number of users requested + * @return int number of Users actually add to Array + */ + protected function _fillGroupUserArray($filter, $numberOfAdds){ + $this->_grpsusers[$this->_filterToString($filter)]; + $i = 0; + $count = 0; + $this->_constructPattern($filter); + foreach ($this->users as $user => &$info) { + if($i++ < $this->_actualstart) { + continue; + } + if($info === false) { + $info = $this->getUserData($user); + } + if($this->_filter($user, $info)) { + $this->_grpsusers[$this->_filterToString($filter)][$user] = $info; + if(($numberOfAdds > 0) && (++$count >= $numberOfAdds)) break; + } + } + $this->_actualstart = $i; + return $count; + } + + /** * Bulk retrieval of user data * * @author Dominik Eckelmann <dokuwiki@cosmocode.de> * - * @param int $start index of first user to be returned - * @param int $limit max number of users to be returned - * @param array $filter array of field/pattern pairs, null for no filter - * @return array userinfo (refer getUserData for internal userinfo details) + * @param int $start index of first user to be returned + * @param int $limit max number of users to be returned + * @param array $filter array of field/pattern pairs, null for no filter + * @return array userinfo (refer getUserData for internal userinfo details) */ public function retrieveUsers($start = 0, $limit = 0, $filter = array()) { $adldap = $this->_adldap(null); @@ -341,27 +470,44 @@ class auth_plugin_authad extends DokuWiki_Auth_Plugin { if(!$this->users) { //get info for given user - $result = $adldap->user()->all(); + $result = $adldap->user()->all(false, $this->_constructSearchString($filter)); if (!$result) return array(); $this->users = array_fill_keys($result, false); } $i = 0; $count = 0; - $this->_constructPattern($filter); $result = array(); - foreach($this->users as $user => &$info) { - if($i++ < $start) { - continue; + if (!isset($filter['grps'])) { + $usermanager = plugin_load("admin", "usermanager", false); + $usermanager->setLastdisabled(false); + $this->_constructPattern($filter); + foreach($this->users as $user => &$info) { + if($i++ < $start) { + continue; + } + if($info === false) { + $info = $this->getUserData($user); + } + $result[$user] = $info; + if(($limit > 0) && (++$count >= $limit)) break; } - if($info === false) { - $info = $this->getUserData($user); + } else { + $usermanager = plugin_load("admin", "usermanager", false); + $usermanager->setLastdisabled(true); + if (!isset($this->_grpsusers[$this->_filterToString($filter)]) || count($this->_grpsusers[$this->_filterToString($filter)]) < ($start+$limit)) { + $this->_fillGroupUserArray($filter,$start+$limit - count($this->_grpsusers[$this->_filterToString($filter)]) +1); } - if($this->_filter($user, $info)) { + if (!$this->_grpsusers[$this->_filterToString($filter)]) return false; + foreach($this->_grpsusers[$this->_filterToString($filter)] as $user => &$info) { + if($i++ < $start) { + continue; + } $result[$user] = $info; if(($limit > 0) && (++$count >= $limit)) break; } + } return $result; } diff --git a/lib/plugins/authad/lang/da/lang.php b/lib/plugins/authad/lang/da/lang.php new file mode 100644 index 000000000..8fc7db775 --- /dev/null +++ b/lib/plugins/authad/lang/da/lang.php @@ -0,0 +1,8 @@ +<?php + +/** + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * + * @author Jacob Palm <mail@jacobpalm.dk> + */ +$lang['domain'] = 'Logondomæne'; diff --git a/lib/plugins/authldap/auth.php b/lib/plugins/authldap/auth.php index 50735882f..9d031c049 100644 --- a/lib/plugins/authldap/auth.php +++ b/lib/plugins/authldap/auth.php @@ -37,7 +37,7 @@ class auth_plugin_authldap extends DokuWiki_Auth_Plugin { } // Add the capabilities to change the password - $this->cando['modPass'] = true; + $this->cando['modPass'] = $this->getConf('modPass'); } /** @@ -360,8 +360,9 @@ class auth_plugin_authldap extends DokuWiki_Auth_Plugin { $sr = ldap_search($this->con, $this->getConf('usertree'), $all_filter); $entries = ldap_get_entries($this->con, $sr); $users_array = array(); + $userkey = $this->getConf('userkey'); for($i = 0; $i < $entries["count"]; $i++) { - array_push($users_array, $entries[$i]["uid"][0]); + array_push($users_array, $entries[$i][$userkey][0]); } asort($users_array); $result = $users_array; diff --git a/lib/plugins/authldap/conf/default.php b/lib/plugins/authldap/conf/default.php index c2e462c5c..116cb9d3f 100644 --- a/lib/plugins/authldap/conf/default.php +++ b/lib/plugins/authldap/conf/default.php @@ -16,5 +16,7 @@ $conf['bindpw'] = ''; //$conf['mapping']['grps'] unsupported in config manager $conf['userscope'] = 'sub'; $conf['groupscope'] = 'sub'; +$conf['userkey'] = 'uid'; $conf['groupkey'] = 'cn'; -$conf['debug'] = 0;
\ No newline at end of file +$conf['debug'] = 0; +$conf['modPass'] = 1; diff --git a/lib/plugins/authldap/conf/metadata.php b/lib/plugins/authldap/conf/metadata.php index 4649ba5bf..a67b11ca6 100644 --- a/lib/plugins/authldap/conf/metadata.php +++ b/lib/plugins/authldap/conf/metadata.php @@ -15,5 +15,7 @@ $meta['bindpw'] = array('password','_caution' => 'danger'); //$meta['mapping']['grps'] unsupported in config manager $meta['userscope'] = array('multichoice','_choices' => array('sub','one','base'),'_caution' => 'danger'); $meta['groupscope'] = array('multichoice','_choices' => array('sub','one','base'),'_caution' => 'danger'); +$meta['userkey'] = array('string','_caution' => 'danger'); $meta['groupkey'] = array('string','_caution' => 'danger'); -$meta['debug'] = array('onoff','_caution' => 'security');
\ No newline at end of file +$meta['debug'] = array('onoff','_caution' => 'security'); +$meta['modPass'] = array('onoff'); diff --git a/lib/plugins/authldap/lang/da/settings.php b/lib/plugins/authldap/lang/da/settings.php index b736504a5..a9fce3a8c 100644 --- a/lib/plugins/authldap/lang/da/settings.php +++ b/lib/plugins/authldap/lang/da/settings.php @@ -5,11 +5,16 @@ * * @author Jens Hyllegaard <jens.hyllegaard@gmail.com> * @author soer9648 <soer9648@eucl.dk> + * @author Jacob Palm <mail@jacobpalm.dk> */ $lang['server'] = 'Din LDAP server. Enten værtsnavn (<code>localhost</code>) eller fuld kvalificeret URL (<code>ldap://server.tld:389</code>)'; $lang['port'] = 'LDAP server port, hvis der ikke er angivet en komplet URL ovenfor.'; $lang['usertree'] = 'Hvor findes brugerkonti. F.eks. <code>ou=Personer, dc=server, dc=tld</code>'; $lang['grouptree'] = 'Hvor findes brugergrupper. F.eks. <code>ou=Grupper, dc=server, dc=tld</code>'; +$lang['userfilter'] = 'LDAP filter der benyttes til at søge efter brugerkonti. F.eks. <code>(&(uid=%{user})(objectClass=posixAccount))</code>'; +$lang['groupfilter'] = 'LDAP filter tder benyttes til at søge efter grupper. F.eks. <code>(&(objectClass=posixGroup)(|(gidNumber=%{gid})(memberUID=%{user})))</code>'; +$lang['version'] = 'Protokol version der skal benyttes. Det er muligvis nødvendigt at sætte denne til <code>3</code>'; $lang['starttls'] = 'Benyt TLS forbindelser?'; $lang['bindpw'] = 'Kodeord til ovenstående bruger'; +$lang['modPass'] = 'Kan LDAP adgangskoden skiftes via DokuWiki?'; $lang['debug'] = 'Vis yderligere debug output ved fejl'; diff --git a/lib/plugins/authldap/lang/de/settings.php b/lib/plugins/authldap/lang/de/settings.php index d788da876..933189c40 100644 --- a/lib/plugins/authldap/lang/de/settings.php +++ b/lib/plugins/authldap/lang/de/settings.php @@ -20,7 +20,9 @@ $lang['binddn'] = 'DN eines optionalen Benutzers, wenn der anonym $lang['bindpw'] = 'Passwort des angegebenen Benutzers.'; $lang['userscope'] = 'Die Suchweite nach Benutzeraccounts.'; $lang['groupscope'] = 'Die Suchweite nach Benutzergruppen.'; +$lang['userkey'] = 'Attribut, das den Benutzernamen enthält; muss konsistent zum userfilter sein.'; $lang['groupkey'] = 'Gruppieren der Benutzeraccounts anhand eines beliebigen Benutzerattributes z. B. Telefonnummer oder Abteilung, anstelle der Standard-Gruppen).'; +$lang['modPass'] = 'Darf über Dokuwiki das LDAP-Passwort geändert werden?'; $lang['debug'] = 'Debug-Informationen beim Auftreten von Fehlern anzeigen?'; $lang['deref_o_0'] = 'LDAP_DEREF_NEVER'; $lang['deref_o_1'] = 'LDAP_DEREF_SEARCHING'; diff --git a/lib/plugins/authldap/lang/en/settings.php b/lib/plugins/authldap/lang/en/settings.php index 951901ccc..a4194b00a 100644 --- a/lib/plugins/authldap/lang/en/settings.php +++ b/lib/plugins/authldap/lang/en/settings.php @@ -13,7 +13,9 @@ $lang['binddn'] = 'DN of an optional bind user if anonymous bind is not suf $lang['bindpw'] = 'Password of above user'; $lang['userscope'] = 'Limit search scope for user search'; $lang['groupscope'] = 'Limit search scope for group search'; +$lang['userkey'] = 'Attribute denoting the username; must be consistent to userfilter.'; $lang['groupkey'] = 'Group membership from any user attribute (instead of standard AD groups) e.g. group from department or telephone number'; +$lang['modPass'] = 'Can the LDAP password be changed via dokuwiki?'; $lang['debug'] = 'Display additional debug information on errors'; diff --git a/lib/plugins/authldap/lang/fr/settings.php b/lib/plugins/authldap/lang/fr/settings.php index dc475071e..aa75105cf 100644 --- a/lib/plugins/authldap/lang/fr/settings.php +++ b/lib/plugins/authldap/lang/fr/settings.php @@ -5,6 +5,7 @@ * * @author Bruno Veilleux <bruno.vey@gmail.com> * @author schplurtz <Schplurtz@laposte.net> + * @author Schplurtz le Déboulonné <schplurtz@laposte.net> */ $lang['server'] = 'Votre serveur LDAP. Soit le nom d\'hôte (<code>localhost</code>) ou l\'URL complète (<code>ldap://serveur.dom:389</code>)'; $lang['port'] = 'Port du serveur LDAP si l\'URL complète n\'a pas été indiquée ci-dessus'; @@ -26,3 +27,6 @@ $lang['deref_o_0'] = 'LDAP_DEREF_NEVER'; $lang['deref_o_1'] = 'LDAP_DEREF_SEARCHING'; $lang['deref_o_2'] = 'LDAP_DEREF_FINDING'; $lang['deref_o_3'] = 'LDAP_DEREF_ALWAYS'; +$lang['referrals_o_-1'] = 'comportement par défaut'; +$lang['referrals_o_0'] = 'ne pas suivre les références'; +$lang['referrals_o_1'] = 'suivre les références'; diff --git a/lib/plugins/authmysql/lang/da/settings.php b/lib/plugins/authmysql/lang/da/settings.php index ed21201fb..5fd66dbad 100644 --- a/lib/plugins/authmysql/lang/da/settings.php +++ b/lib/plugins/authmysql/lang/da/settings.php @@ -5,6 +5,7 @@ * * @author Jens Hyllegaard <jens.hyllegaard@gmail.com> * @author soer9648 <soer9648@eucl.dk> + * @author Jacob Palm <mail@jacobpalm.dk> */ $lang['server'] = 'Din MySQL server'; $lang['user'] = 'MySQL brugernavn'; @@ -12,8 +13,11 @@ $lang['password'] = 'Kodeord til ovenstående bruger'; $lang['database'] = 'Database der skal benyttes'; $lang['charset'] = 'Tegnsæt benyttet i database'; $lang['debug'] = 'Vis yderligere debug output'; +$lang['forwardClearPass'] = 'Videregiv bruger adgangskoder i klar tekst til nedenstående SQL statement, i stedet for at benytte passcrypt'; +$lang['TablesToLock'] = 'Kommasepareret liste over tabeller der skal låses under skrivning'; $lang['checkPass'] = 'SQL-sætning til at kontrollere kodeord'; $lang['getUserInfo'] = 'SQL-sætning til at hente brugerinformation'; +$lang['getGroups'] = 'SQL statement til at bestemme en brugers medlemskab af grupper'; $lang['getUsers'] = 'SQL-sætning til at liste alle brugere'; $lang['addUser'] = 'SQL-sætning til at tilføje en ny bruger'; $lang['addGroup'] = 'SQL-sætning til at tilføje en ny gruppe'; diff --git a/lib/plugins/extension/lang/da/intro_install.txt b/lib/plugins/extension/lang/da/intro_install.txt new file mode 100644 index 000000000..e5657f218 --- /dev/null +++ b/lib/plugins/extension/lang/da/intro_install.txt @@ -0,0 +1 @@ +Her kan du installerer plugins eller templates manuelt, ved enten at uploade dem eller angive en direkte URL til download.
\ No newline at end of file diff --git a/lib/plugins/extension/lang/da/intro_plugins.txt b/lib/plugins/extension/lang/da/intro_plugins.txt new file mode 100644 index 000000000..5d9deaf1e --- /dev/null +++ b/lib/plugins/extension/lang/da/intro_plugins.txt @@ -0,0 +1 @@ +Dette er de plugins du aktuelt har installeret i din DokuWiki. Du kan aktivere, deaktiver eller fjerne plugins fra denne side. Opdateringer til plugins vises også her - husk at læse dokumentationen til et plugin inden du opdaterer det.
\ No newline at end of file diff --git a/lib/plugins/extension/lang/da/intro_templates.txt b/lib/plugins/extension/lang/da/intro_templates.txt new file mode 100644 index 000000000..1914500b1 --- /dev/null +++ b/lib/plugins/extension/lang/da/intro_templates.txt @@ -0,0 +1 @@ +Dette er de templates du aktuelt har installeret i din DokuWiki. Du kan vælge det template du vil benytte under [[?do=admin&page=config|Opsætningsstyring]].
\ No newline at end of file diff --git a/lib/plugins/extension/lang/da/lang.php b/lib/plugins/extension/lang/da/lang.php index c341bc5f9..17cb3b57c 100644 --- a/lib/plugins/extension/lang/da/lang.php +++ b/lib/plugins/extension/lang/da/lang.php @@ -4,7 +4,62 @@ * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) * * @author Søren Birk <soer9648@eucl.dk> + * @author Jacob Palm <mail@jacobpalm.dk> */ +$lang['tab_plugins'] = 'Installerede plugins'; +$lang['tab_templates'] = 'Installerede templates'; +$lang['tab_search'] = 'Søg og installer'; +$lang['tab_install'] = 'Manuel installation'; +$lang['notimplemented'] = 'Denne funktion er ikke implementeret endnu'; +$lang['unknownauthor'] = 'Ukendt udgiver'; +$lang['unknownversion'] = 'Ukendt version'; +$lang['btn_info'] = 'Vis mere information'; +$lang['btn_update'] = 'Opdater'; +$lang['btn_uninstall'] = 'Afinstaller'; +$lang['btn_enable'] = 'Aktiver'; +$lang['btn_disable'] = 'Deaktiver'; +$lang['btn_install'] = 'Installer'; +$lang['btn_reinstall'] = 'Geninstaller'; +$lang['js']['reallydel'] = 'Er du sikker på at du vil afinstallere denne udvidelse?'; +$lang['search_for'] = 'Søg efter udvidelse:'; +$lang['search'] = 'Søg'; +$lang['extensionby'] = '<strong>%s</strong> af %s'; +$lang['screenshot'] = 'Skærmbillede af %s'; +$lang['popularity'] = 'Popularitet: %s%%'; +$lang['homepage_link'] = 'Dokumenter'; +$lang['bugs_features'] = 'Fejl'; +$lang['tags'] = 'Tags:'; +$lang['author_hint'] = 'Søg efter udvidelse af denne udgiver'; +$lang['installed'] = 'Installeret:'; +$lang['downloadurl'] = 'Download URL:'; +$lang['unknown'] = '<em>ukendt</em>'; +$lang['installed_version'] = 'Installeret version:'; +$lang['install_date'] = 'Din sidste opdatering:'; +$lang['available_version'] = 'Tilgængelig version:'; +$lang['compatible'] = 'Kompatibel med:'; +$lang['depends'] = 'Afhængig af:'; +$lang['similar'] = 'Ligner:'; +$lang['donate'] = 'Synes du om denne?'; +$lang['donate_action'] = 'Køb en kop kaffe til udvikleren!'; +$lang['repo_retry'] = 'Førsøg igen'; +$lang['status'] = 'Status:'; +$lang['status_installed'] = 'installeret'; +$lang['status_not_installed'] = 'ikke installeret'; +$lang['status_protected'] = 'beskyttet'; +$lang['status_enabled'] = 'aktiveret'; +$lang['status_disabled'] = 'deaktiveret'; +$lang['status_unmodifiable'] = 'låst for ændringer'; +$lang['status_plugin'] = 'plugin'; +$lang['status_template'] = 'template'; +$lang['msg_enabled'] = 'Plugin %s aktiveret'; +$lang['msg_disabled'] = 'Plugin %s deaktiveret'; +$lang['msg_delete_success'] = 'Udvidelse %s afinstalleret'; +$lang['msg_delete_failed'] = 'Kunne ikke afinstallere udvidelsen %s'; +$lang['msg_template_install_success'] = 'Template %s blev installeret'; +$lang['msg_template_update_success'] = 'Template %s blev opdateret'; +$lang['msg_plugin_install_success'] = 'Plugin %s blev installeret'; +$lang['msg_plugin_update_success'] = 'Plugin %s blev opdateret'; +$lang['msg_upload_failed'] = 'Kunne ikke uploade filen'; $lang['update_available'] = '<strong>Opdatering:</strong> Ny version %s er tilgængelig.'; $lang['wrong_folder'] = '<strong>Plugin ikke installeret korrekt:</strong> Omdøb plugin-mappe "%s" til "%s".'; $lang['url_change'] = '<strong>URL ændret:</strong> Download-URL er blevet ændret siden sidste download. Kontrollér om den nye URL er valid, inden udvidelsen opdateres.<br />Ny: %s<br />Gammel: %s'; @@ -22,3 +77,4 @@ $lang['auth'] = 'Auth-plugin er ikke aktiveret i konfiguratione $lang['install_url'] = 'Installér fra URL:'; $lang['install_upload'] = 'Upload Udvidelse:'; $lang['repo_error'] = 'Plugin-arkivet kunne ikke kontaktes. Kontrollér at din server kan kontakte www.dokuwiki.org kontrollér dine proxy-indstillinger.'; +$lang['nossl'] = 'Din PHP lader til at mangle understøttelse for SSL. Mange DokuWiki udvidelser vil ikke kunne downloades.'; diff --git a/lib/plugins/extension/lang/es/lang.php b/lib/plugins/extension/lang/es/lang.php index 63742c3b3..a835cb630 100644 --- a/lib/plugins/extension/lang/es/lang.php +++ b/lib/plugins/extension/lang/es/lang.php @@ -6,6 +6,7 @@ * @author Antonio Bueno <atnbueno@gmail.com> * @author Antonio Castilla <antoniocastilla@trazoide.com> * @author Jonathan Hernández <me@jhalicea.com> + * @author Álvaro Iradier <airadier@gmail.com> */ $lang['menu'] = 'Administrador de Extensiones '; $lang['tab_plugins'] = 'Plugins instalados'; @@ -64,6 +65,7 @@ $lang['status_bundled'] = 'agrupado'; $lang['msg_enabled'] = 'Plugin %s activado'; $lang['msg_disabled'] = 'Plugin %s desactivado'; $lang['msg_delete_success'] = 'Extensión desinstalada'; +$lang['msg_delete_failed'] = 'La desinstalación de la extensión %s ha fallado'; $lang['msg_template_install_success'] = 'Plantilla %s instalada con éxito'; $lang['msg_template_update_success'] = 'Plantilla %s actualizada con éxito'; $lang['msg_plugin_install_success'] = 'Plugin %s instalado con éxito'; @@ -78,6 +80,9 @@ $lang['url_change'] = '<strong>URL actualizada:</strong> El Download $lang['error_badurl'] = 'URLs deberían empezar con http o https'; $lang['error_dircreate'] = 'No es posible de crear un directorio temporero para poder recibir el download'; $lang['error_download'] = 'No es posible descargar el documento: %s'; +$lang['error_decompress'] = 'No se pudo descomprimir el fichero descargado. Puede ser a causa de una descarga incorrecta, en cuyo caso puedes intentarlo de nuevo; o puede que el formato de compresión sea desconocido, en cuyo caso necesitarás descargar e instalar manualmente.'; +$lang['noperms'] = 'El directorio de extensiones no tiene permiso de escritura.'; +$lang['notplperms'] = 'El directorio de plantillas no tiene permiso de escritura.'; $lang['git'] = 'Esta extensión fue instalada a través de git, quizás usted no quiera actualizarla aquí mismo.'; $lang['install_url'] = 'Instalar desde URL:'; $lang['install_upload'] = 'Subir Extensión:'; diff --git a/lib/plugins/usermanager/admin.php b/lib/plugins/usermanager/admin.php index 86562f1dd..9cb9b0c40 100644 --- a/lib/plugins/usermanager/admin.php +++ b/lib/plugins/usermanager/admin.php @@ -31,6 +31,7 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { protected $_edit_userdata = array(); protected $_disabled = ''; // if disabled set to explanatory string protected $_import_failures = array(); + protected $_lastdisabled = false; // set to true if last user is unknown and last button is hence buggy /** * Constructor @@ -82,6 +83,27 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { } /** + * @return int current start value for pageination + */ + public function getStart() { + return $this->_start; + } + + /** + * @return int number of users per page + */ + public function getPagesize() { + return $this->_pagesize; + } + + /** + * @param boolean $lastdisabled + */ + public function setLastdisabled($lastdisabled) { + $this->_lastdisabled = $lastdisabled; + } + + /** * Handle user request * * @return bool @@ -200,9 +222,9 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { */ $groups = join(', ',$grps); ptln(" <tr class=\"user_info\">"); - ptln(" <td class=\"centeralign\"><input type=\"checkbox\" name=\"delete[".$user."]\" ".$delete_disable." /></td>"); + ptln(" <td class=\"centeralign\"><input type=\"checkbox\" name=\"delete[".hsc($user)."]\" ".$delete_disable." /></td>"); if ($editable) { - ptln(" <td><a href=\"".wl($ID,array('fn[edit]['.hsc($user).']' => 1, + ptln(" <td><a href=\"".wl($ID,array('fn[edit]['.$user.']' => 1, 'do' => 'admin', 'page' => 'usermanager', 'sectok' => getSecurityToken())). @@ -334,7 +356,7 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { // save current $user, we need this to access details if the name is changed if ($user) - ptln(" <input type=\"hidden\" name=\"userid_old\" value=\"".$user."\" />",$indent); + ptln(" <input type=\"hidden\" name=\"userid_old\" value=\"".hsc($user)."\" />",$indent); $this->_htmlFilterSettings($indent+10); @@ -379,6 +401,7 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { $fieldtype = 'text'; $autocomp = ''; } + $value = hsc($value); echo "<tr $class>"; echo "<td><label for=\"$id\" >$label: </label></td>"; @@ -836,6 +859,10 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin { $buttons['last'] = $buttons['next'] = (($this->_start + $this->_pagesize) >= $this->_user_total) ? $disabled : ''; } + if ($this->_lastdisabled) { + $buttons['last'] = $disabled; + } + return $buttons; } diff --git a/lib/tpl/dokuwiki/css/design.less b/lib/tpl/dokuwiki/css/design.less index 66607b5e9..548ba7228 100644 --- a/lib/tpl/dokuwiki/css/design.less +++ b/lib/tpl/dokuwiki/css/design.less @@ -349,11 +349,12 @@ form.search { ********************************************************************/ .dokuwiki .pageId { - position: absolute; - top: -2.3em; - right: -1em; + float: right; + margin-right: -1em; + margin-bottom: -1px; + margin-top: -1.5em; overflow: hidden; - padding: 1em 1em 0; + padding: 0.5em 1em 0; span { font-size: 0.875em; @@ -370,6 +371,7 @@ form.search { } .dokuwiki div.page { + clear: both; background: @ini_background; color: inherit; border: 1px solid @ini_background_alt; @@ -396,8 +398,9 @@ form.search { } [dir=rtl] .dokuwiki .pageId { - right: auto; - left: -1em; + float: left; + margin-left: -1em; + margin-right: 0; } /* footer diff --git a/lib/tpl/dokuwiki/css/mixins.less b/lib/tpl/dokuwiki/css/mixins.less index a88767e97..4b15bb600 100644 --- a/lib/tpl/dokuwiki/css/mixins.less +++ b/lib/tpl/dokuwiki/css/mixins.less @@ -7,4 +7,17 @@ background: -o-linear-gradient( @declaration); background: -ms-linear-gradient( @declaration); background: linear-gradient( @declaration); -}
\ No newline at end of file +} + +/** + * provides inline list styling. + */ +.inline-list(){ + list-style-type: none; + + & li { + margin: 0; + padding: 0; + display: inline; + } +} diff --git a/lib/tpl/dokuwiki/css/mobile.less b/lib/tpl/dokuwiki/css/mobile.less index c3e517795..e5e13e221 100644 --- a/lib/tpl/dokuwiki/css/mobile.less +++ b/lib/tpl/dokuwiki/css/mobile.less @@ -23,6 +23,7 @@ #dokuwiki__aside { width: 100%; float: none; + margin-bottom: 1.5em; } #dokuwiki__aside > .pad, @@ -158,6 +159,11 @@ body { padding: 0 .5em; } } + +#dokuwiki__aside { + margin-bottom: 0; +} + #dokuwiki__header { padding: .5em 0; } diff --git a/lib/tpl/dokuwiki/css/print.css b/lib/tpl/dokuwiki/css/print.css index 86e686b69..7197ac1c1 100644 --- a/lib/tpl/dokuwiki/css/print.css +++ b/lib/tpl/dokuwiki/css/print.css @@ -111,6 +111,9 @@ blockquote { } /* tables */ +.dokuwiki div.table { + margin-bottom: 1.4em; +} table { border-collapse: collapse; empty-cells: show; diff --git a/lib/tpl/dokuwiki/css/structure.less b/lib/tpl/dokuwiki/css/structure.less index 3ea2f83eb..f7dea3948 100644 --- a/lib/tpl/dokuwiki/css/structure.less +++ b/lib/tpl/dokuwiki/css/structure.less @@ -87,3 +87,18 @@ body { #dokuwiki__footer { clear: both; } + +.dokuwiki .navlist { + display: inline; + padding: 0; + .inline-list; +} + +.bchead { + display: inline; + font-size: inherit; +} + +.curid { + font-weight: bold; +} diff --git a/lib/tpl/dokuwiki/detail.php b/lib/tpl/dokuwiki/detail.php index d4f9c39d1..b27567987 100644 --- a/lib/tpl/dokuwiki/detail.php +++ b/lib/tpl/dokuwiki/detail.php @@ -36,6 +36,7 @@ header('X-UA-Compatible: IE=edge,chrome=1'); <!-- ********** CONTENT ********** --> <div id="dokuwiki__content"><div class="pad group"> + <?php html_msgarea() ?> <?php if(!$ERROR): ?> <div class="pageId"><span><?php echo hsc(tpl_img_getTag('IPTC.Headline',$IMG)); ?></span></div> diff --git a/lib/tpl/dokuwiki/main.php b/lib/tpl/dokuwiki/main.php index 10c0bf91e..165230e8a 100644 --- a/lib/tpl/dokuwiki/main.php +++ b/lib/tpl/dokuwiki/main.php @@ -49,6 +49,7 @@ $showSidebar = $hasSidebar && ($ACT=='show'); <!-- ********** CONTENT ********** --> <div id="dokuwiki__content"><div class="pad group"> + <?php html_msgarea() ?> <div class="pageId"><span><?php echo hsc($ID) ?></span></div> diff --git a/lib/tpl/dokuwiki/tpl_header.php b/lib/tpl/dokuwiki/tpl_header.php index 7d9c88347..ee51cbd01 100644 --- a/lib/tpl/dokuwiki/tpl_header.php +++ b/lib/tpl/dokuwiki/tpl_header.php @@ -85,7 +85,7 @@ if (!defined('DOKU_INC')) die(); </div> <?php endif ?> - <?php html_msgarea() ?> + <hr class="a11y" /> </div></div><!-- /header --> |