diff options
Diffstat (limited to 'lib/plugins/acl')
34 files changed, 167 insertions, 135 deletions
diff --git a/lib/plugins/acl/action.php b/lib/plugins/acl/action.php new file mode 100644 index 000000000..a7226f598 --- /dev/null +++ b/lib/plugins/acl/action.php @@ -0,0 +1,88 @@ +<?php +/** + * AJAX call handler for ACL plugin + * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * @author Andreas Gohr <andi@splitbrain.org> + */ + +// must be run within Dokuwiki +if(!defined('DOKU_INC')) die(); + +/** + * Register handler + */ +class action_plugin_acl extends DokuWiki_Action_Plugin { + + /** + * Registers a callback function for a given event + * + * @param Doku_Event_Handler $controller DokuWiki's event controller object + * @return void + */ + public function register(Doku_Event_Handler $controller) { + + $controller->register_hook('AJAX_CALL_UNKNOWN', 'BEFORE', $this, 'handle_ajax_call_acl'); + + } + + /** + * AJAX call handler for ACL plugin + * + * @param Doku_Event $event event object by reference + * @param mixed $param empty + * @return void + */ + + public function handle_ajax_call_acl(Doku_Event &$event, $param) { + if($event->data !== 'plugin_acl') { + return; + } + $event->stopPropagation(); + $event->preventDefault(); + + global $ID; + global $INPUT; + + if(!auth_isadmin()) { + echo 'for admins only'; + return; + } + if(!checkSecurityToken()) { + echo 'CRSF Attack'; + return; + } + + $ID = getID(); + + /** @var $acl admin_plugin_acl */ + $acl = plugin_load('admin', 'acl'); + $acl->handle(); + + $ajax = $INPUT->str('ajax'); + header('Content-Type: text/html; charset=utf-8'); + + if($ajax == 'info') { + $acl->_html_info(); + } elseif($ajax == 'tree') { + + $ns = $INPUT->str('ns'); + if($ns == '*') { + $ns = ''; + } + $ns = cleanID($ns); + $lvl = count(explode(':', $ns)); + $ns = utf8_encodeFN(str_replace(':', '/', $ns)); + + $data = $acl->_get_tree($ns, $ns); + + foreach(array_keys($data) as $item) { + $data[$item]['level'] = $lvl + 1; + } + echo html_buildlist( + $data, 'acl', array($acl, '_html_list_acl'), + array($acl, '_html_li_acl') + ); + } + } +} diff --git a/lib/plugins/acl/admin.php b/lib/plugins/acl/admin.php index 50377da81..b24981d91 100644 --- a/lib/plugins/acl/admin.php +++ b/lib/plugins/acl/admin.php @@ -61,7 +61,6 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { // fresh 1:1 copy without replacements $AUTH_ACL = file($config_cascade['acl']['default']); - // namespace given? if($INPUT->str('ns') == '*'){ $this->ns = '*'; @@ -386,7 +385,6 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { echo '<legend>'.$this->getLang('acl_mod').'</legend>'; } - echo $this->_html_checkboxes($current,empty($this->ns),'acl'); if(is_null($current)){ @@ -556,7 +554,7 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { $line = trim(preg_replace('/#.*$/','',$line)); //ignore comments if(!$line) continue; - $acl = preg_split('/\s+/',$line); + $acl = preg_split('/[ \t]+/',$line); //0 is pagename, 1 is user, 2 is acl $acl[1] = rawurldecode($acl[1]); @@ -686,7 +684,6 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { if($acl_level > AUTH_EDIT) $acl_level = AUTH_EDIT; } - $new_acl = "$acl_scope\t$acl_user\t$acl_level\n"; $new_config = $acl_config.$new_acl; @@ -704,7 +701,7 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { $acl_config = file($config_cascade['acl']['default']); $acl_user = auth_nameencode($acl_user,true); - $acl_pattern = '^'.preg_quote($acl_scope,'/').'\s+'.$acl_user.'\s+[0-8].*$'; + $acl_pattern = '^'.preg_quote($acl_scope,'/').'[ \t]+'.$acl_user.'[ \t]+[0-8].*$'; // save all non!-matching $new_config = preg_grep("/$acl_pattern/", $acl_config, PREG_GREP_INVERT); @@ -775,7 +772,6 @@ class admin_plugin_acl extends DokuWiki_Admin_Plugin { $inlist = true; } - echo '<select name="acl_t" class="edit">'.NL; echo ' <option value="__g__" class="aclgroup"'.$gsel.'>'.$this->getLang('acl_group').':</option>'.NL; echo ' <option value="__u__" class="acluser"'.$usel.'>'.$this->getLang('acl_user').':</option>'.NL; diff --git a/lib/plugins/acl/ajax.php b/lib/plugins/acl/ajax.php deleted file mode 100644 index 10e18af97..000000000 --- a/lib/plugins/acl/ajax.php +++ /dev/null @@ -1,57 +0,0 @@ -<?php -/** - * AJAX call handler for ACL plugin - * - * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) - * @author Andreas Gohr <andi@splitbrain.org> - */ - -if(!defined('DOKU_INC')) define('DOKU_INC',dirname(__FILE__).'/../../../'); -require_once(DOKU_INC.'inc/init.php'); -//close session -session_write_close(); - -global $conf; -global $ID; -global $INPUT; - -//fix for Opera XMLHttpRequests -$postData = http_get_raw_post_data(); -if(!count($_POST) && !empty($postData)){ - parse_str($postData, $_POST); -} - -if(!auth_isadmin()) die('for admins only'); -if(!checkSecurityToken()) die('CRSF Attack'); - -$ID = getID(); - -/** @var $acl admin_plugin_acl */ -$acl = plugin_load('admin','acl'); -$acl->handle(); - -$ajax = $INPUT->str('ajax'); -header('Content-Type: text/html; charset=utf-8'); - -if($ajax == 'info'){ - $acl->_html_info(); -}elseif($ajax == 'tree'){ - - $dir = $conf['datadir']; - $ns = $INPUT->str('ns'); - if($ns == '*'){ - $ns =''; - } - $ns = cleanID($ns); - $lvl = count(explode(':',$ns)); - $ns = utf8_encodeFN(str_replace(':','/',$ns)); - - $data = $acl->_get_tree($ns,$ns); - - foreach(array_keys($data) as $item){ - $data[$item]['level'] = $lvl+1; - } - echo html_buildlist($data, 'acl', array($acl, '_html_list_acl'), - array($acl, '_html_li_acl')); -} - diff --git a/lib/plugins/acl/lang/ar/lang.php b/lib/plugins/acl/lang/ar/lang.php index 7c05b721c..4e44dab5f 100644 --- a/lib/plugins/acl/lang/ar/lang.php +++ b/lib/plugins/acl/lang/ar/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Arabic language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Mostafa Hussein <mostafa@gmail.com> * @author Yaman Hokan <always.smile.yh@hotmail.com> * @author Usama Akkad <uahello@gmail.com> diff --git a/lib/plugins/acl/lang/cs/lang.php b/lib/plugins/acl/lang/cs/lang.php index a4e59287a..8031612f7 100644 --- a/lib/plugins/acl/lang/cs/lang.php +++ b/lib/plugins/acl/lang/cs/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Czech language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Bohumir Zamecnik <bohumir@zamecnik.org> * @author Zbynek Krivka <zbynek.krivka@seznam.cz> * @author tomas@valenta.cz diff --git a/lib/plugins/acl/lang/da/lang.php b/lib/plugins/acl/lang/da/lang.php index 4a9d11448..2558795fd 100644 --- a/lib/plugins/acl/lang/da/lang.php +++ b/lib/plugins/acl/lang/da/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Danish language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author koeppe <koeppe@kazur.dk> * @author Jon Bendtsen <bendtsen@diku.dk> * @author Lars Næsbye Christensen <larsnaesbye@stud.ku.dk> diff --git a/lib/plugins/acl/lang/de-informal/lang.php b/lib/plugins/acl/lang/de-informal/lang.php index 3487f4257..35df13dc0 100644 --- a/lib/plugins/acl/lang/de-informal/lang.php +++ b/lib/plugins/acl/lang/de-informal/lang.php @@ -1,7 +1,8 @@ <?php + /** - * German (informal) language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Alexander Fischer <tbanus@os-forge.net> * @author Juergen Schwarzer <jschwarzer@freenet.de> * @author Marcel Metz <marcel_metz@gmx.de> diff --git a/lib/plugins/acl/lang/de/lang.php b/lib/plugins/acl/lang/de/lang.php index 5f3e51a32..77de4b097 100644 --- a/lib/plugins/acl/lang/de/lang.php +++ b/lib/plugins/acl/lang/de/lang.php @@ -1,8 +1,8 @@ <?php + /** - * german language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Andreas Gohr <andi@splitbrain.org> * @author Christof <gagi@fin.de> * @author Anika Henke <anika@selfthinker.org> diff --git a/lib/plugins/acl/lang/el/lang.php b/lib/plugins/acl/lang/el/lang.php index 516d7bdf5..dc4a9f034 100644 --- a/lib/plugins/acl/lang/el/lang.php +++ b/lib/plugins/acl/lang/el/lang.php @@ -1,11 +1,8 @@ <?php + /** - * Greek language file - * - * Based on DokuWiki Version rc2007-05-24 english language file - * Original english language file contents included for reference - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Andreas Gohr <andi@splitbrain.org> * @author Anika Henke <anika@selfthinker.org> * @author Matthias Grimm <matthiasgrimm@users.sourceforge.net> diff --git a/lib/plugins/acl/lang/eo/lang.php b/lib/plugins/acl/lang/eo/lang.php index de75c2dd7..a5f607341 100644 --- a/lib/plugins/acl/lang/eo/lang.php +++ b/lib/plugins/acl/lang/eo/lang.php @@ -1,7 +1,8 @@ <?php + /** - * Esperanto language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Felipe Castro <fefcas@uol.com.br> * @author Felipo Kastro <fefcas@gmail.com> * @author Felipe Castro <fefcas@gmail.com> diff --git a/lib/plugins/acl/lang/es/lang.php b/lib/plugins/acl/lang/es/lang.php index b60033e0f..cf503d4d1 100644 --- a/lib/plugins/acl/lang/es/lang.php +++ b/lib/plugins/acl/lang/es/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Spanish language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Miguel Pagano <miguel.pagano@gmail.com> * @author Oscar M. Lage <r0sk10@gmail.com> * @author Gabriel Castillo <gch@pumas.ii.unam.mx> diff --git a/lib/plugins/acl/lang/fa/lang.php b/lib/plugins/acl/lang/fa/lang.php index 7fe0f2c43..24bebaeaf 100644 --- a/lib/plugins/acl/lang/fa/lang.php +++ b/lib/plugins/acl/lang/fa/lang.php @@ -1,7 +1,8 @@ <?php + /** - * Persian language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author behrad eslamifar <behrad_es@yahoo.com) * @author Mohsen Firoozmandan <info@mambolearn.com> * @author omidmr@gmail.com diff --git a/lib/plugins/acl/lang/fr/lang.php b/lib/plugins/acl/lang/fr/lang.php index 538dd14d3..dc17cf79e 100644 --- a/lib/plugins/acl/lang/fr/lang.php +++ b/lib/plugins/acl/lang/fr/lang.php @@ -1,8 +1,8 @@ <?php + /** - * french language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Sébastien Bauer <sebastien.bauer@advalvas.be> * @author Antoine Fixary <antoine.fixary@freesbee.fr> * @author cumulus <pta-n56@myamail.com> diff --git a/lib/plugins/acl/lang/he/lang.php b/lib/plugins/acl/lang/he/lang.php index 91025f4b8..6716081eb 100644 --- a/lib/plugins/acl/lang/he/lang.php +++ b/lib/plugins/acl/lang/he/lang.php @@ -1,8 +1,8 @@ <?php + /** - * hebrew language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author DoK <kamberd@yahoo.com> * @author Dotan Kamber <kamberd@yahoo.com> * @author Moshe Kaplan <mokplan@gmail.com> diff --git a/lib/plugins/acl/lang/hu/lang.php b/lib/plugins/acl/lang/hu/lang.php index 9565eddc3..cc35243e1 100644 --- a/lib/plugins/acl/lang/hu/lang.php +++ b/lib/plugins/acl/lang/hu/lang.php @@ -1,7 +1,8 @@ <?php + /** - * Hungarian language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Sandor TIHANYI <stihanyi+dw@gmail.com> * @author Siaynoq Mage <siaynoqmage@gmail.com> * @author schilling.janos@gmail.com diff --git a/lib/plugins/acl/lang/it/lang.php b/lib/plugins/acl/lang/it/lang.php index 07e86697d..ba2d0fd32 100644 --- a/lib/plugins/acl/lang/it/lang.php +++ b/lib/plugins/acl/lang/it/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Italian language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Giorgio Vecchiocattivi <giorgio@vecchio.it> * @author Roberto Bolli <http://www.rbnet.it/> * @author Pietro Battiston toobaz@email.it diff --git a/lib/plugins/acl/lang/ja/lang.php b/lib/plugins/acl/lang/ja/lang.php index 0dd4d09c6..61fc1ea86 100644 --- a/lib/plugins/acl/lang/ja/lang.php +++ b/lib/plugins/acl/lang/ja/lang.php @@ -1,8 +1,8 @@ <?php + /** - * japanese language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Davilin(Yuji Takenaka) <webmaster@davilin.com> * @author Yuji Takenaka <webmaster@davilin.com> * @author Ikuo Obataya <i.obataya@gmail.com> diff --git a/lib/plugins/acl/lang/ko/help.txt b/lib/plugins/acl/lang/ko/help.txt index ba3dd6d9f..9baeedbb9 100644 --- a/lib/plugins/acl/lang/ko/help.txt +++ b/lib/plugins/acl/lang/ko/help.txt @@ -5,4 +5,4 @@ * 위쪽 입력 양식에서 선택된 사용자와 그룹의 접근 권한을 보거나 바꿀 수 있습니다. * 아래 테이블에서 현재 설정된 모든 접근 제어 규칙을 볼 수 있으며, 즉시 여러 규칙을 삭제하거나 바꿀 수 있습니다. -DokuWiki에서 접근 제어가 어떻게 동작되는지 알아보려면 [[doku>ko:acl|ACL 공식 문서]]를 읽어보시기 바랍니다.
\ No newline at end of file +도쿠위키에서 접근 제어가 어떻게 동작되는지 알아보려면 [[doku>ko:acl|ACL 공식 문서]]를 읽어보시기 바랍니다.
\ No newline at end of file diff --git a/lib/plugins/acl/lang/ko/lang.php b/lib/plugins/acl/lang/ko/lang.php index 7c1e9a43d..2f1ba2311 100644 --- a/lib/plugins/acl/lang/ko/lang.php +++ b/lib/plugins/acl/lang/ko/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Korean language file - * - * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Andreas Gohr <andi@splitbrain.org> * @author Anika Henke <anika@selfthinker.org> * @author Matthias Grimm <matthiasgrimm@users.sourceforge.net> diff --git a/lib/plugins/acl/lang/ne/lang.php b/lib/plugins/acl/lang/ne/lang.php index 6a29a9fa8..5e6196a30 100644 --- a/lib/plugins/acl/lang/ne/lang.php +++ b/lib/plugins/acl/lang/ne/lang.php @@ -1,7 +1,8 @@ <?php + /** - * Nepali language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Saroj Kumar Dhakal <lotusnagarkot@gmail.com> * @author SarojKumar Dhakal <lotusnagarkot@yahoo.com> * @author Saroj Dhakal<lotusnagarkot@yahoo.com> diff --git a/lib/plugins/acl/lang/nl/lang.php b/lib/plugins/acl/lang/nl/lang.php index e3a95e779..abb81ae06 100644 --- a/lib/plugins/acl/lang/nl/lang.php +++ b/lib/plugins/acl/lang/nl/lang.php @@ -19,6 +19,8 @@ * @author Jeroen * @author Ricardo Guijt <ricardoguijt@gmail.com> * @author Gerrit <klapinklapin@gmail.com> + * @author Gerrit Uitslag <klapinklapin@gmail.com> + * @author Remon <no@email.local> */ $lang['admin_acl'] = 'Toegangsrechten'; $lang['acl_group'] = 'Groep'; @@ -30,14 +32,14 @@ $lang['btn_select'] = 'Selecteer'; $lang['p_user_id'] = 'Gebruiker <b class="acluser">%s</b> heeft momenteel de volgende bevoegdheden op pagina <b class="aclpage">%s</b>: <i>%s</i>.'; $lang['p_user_ns'] = 'Gebruiker <b class="acluser">%s</b> heeft momenteel de volgende bevoegdheden op namespace <b class="aclns">%s</b>: <i>%s</i>.'; $lang['p_group_id'] = 'Leden van groep <b class="aclgroup">%s</b> hebben momenteel de volgende bevoegdheden op pagina <b class="aclpage">%s</b>: <i>%s</i>.'; -$lang['p_group_ns'] = 'Leden van groep <b class="aclgroup">%s</b>hebben momenteel de volgende bevoegdheden op namespace <b class="aclns">%s</b>: <i>%s</i>.'; +$lang['p_group_ns'] = 'Leden van groep <b class="aclgroup">%s</b> hebben momenteel de volgende bevoegdheden in namespace <b class="aclns">%s</b>: <i>%s</i>.'; $lang['p_choose_id'] = 'Vul een <b>gebruiker of groep</b> in in het bovenstaande formulier om de bevoegdheden te bekijken of te bewerken voor de pagina <b class="aclpage">%s</b>.'; $lang['p_choose_ns'] = 'Vul een <b>gebruiker of groep</b> in in het bovenstaande formulier om de bevoegdheden te bekijken of te bewerken voor de namespace <b class="aclns">%s</b>.'; $lang['p_inherited'] = 'Let op: Deze permissies zijn niet expliciet ingesteld maar overerfd van andere groepen of hogere namespaces.'; $lang['p_isadmin'] = 'Let op: De geselecteerde groep of gebruiker heeft altijd volledige toegangsrechten omdat hij als superuser geconfigureerd is.'; $lang['p_include'] = 'Hogere permissies bevatten ook de lagere. Aanmaken, uploaden en verwijderen gelden alleen voor namespaces, niet voor pagina\'s.'; $lang['current'] = 'Huidige ACL regels'; -$lang['where'] = 'Pagina/namespace'; +$lang['where'] = 'Pagina/Namespace'; $lang['who'] = 'Gebruiker/Groep'; $lang['perm'] = 'Bevoegdheden'; $lang['acl_perm0'] = 'Geen'; diff --git a/lib/plugins/acl/lang/pt-br/lang.php b/lib/plugins/acl/lang/pt-br/lang.php index c49b430f8..ef0ae6c8b 100644 --- a/lib/plugins/acl/lang/pt-br/lang.php +++ b/lib/plugins/acl/lang/pt-br/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Brazilian Portuguese language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Luis Fernando Enciso <lfenciso@certto.com.br> * @author Alauton/Loug * @author Frederico Gonçalves Guimarães <frederico@teia.bio.br> diff --git a/lib/plugins/acl/lang/pt/lang.php b/lib/plugins/acl/lang/pt/lang.php index d90bab624..4c2114d67 100644 --- a/lib/plugins/acl/lang/pt/lang.php +++ b/lib/plugins/acl/lang/pt/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Portuguese language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author José Carlos Monteiro <jose.c.monteiro@netcabo.pt> * @author José Monteiro <Jose.Monteiro@DoWeDo-IT.com> * @author Enrico Nicoletto <liverig@gmail.com> diff --git a/lib/plugins/acl/lang/ru/help.txt b/lib/plugins/acl/lang/ru/help.txt index 7807105a8..ecb2fe3d0 100644 --- a/lib/plugins/acl/lang/ru/help.txt +++ b/lib/plugins/acl/lang/ru/help.txt @@ -1,7 +1,8 @@ === Краткая справка === -На этой странице вы можете добавить или удалить права доступа к пространствам имён и страницам своей вики.\\ -На панели слева отображены доступные пространства имён и страницы.\\ -Форма выше позволяет вам просмотреть и изменить права доступа для выбранного пользователя или группы.\\ -Текущие права доступа отображены в таблице ниже. Вы можете использовать её для быстрого удаления или изменения правил.\\ +На этой странице вы можете добавить или удалить права доступа к пространствам имён и страницам своей вики. + * На панели слева отображены доступные пространства имён и страницы. + * Форма выше позволяет вам просмотреть и изменить права доступа для выбранного пользователя или группы. + * Текущие права доступа отображены в таблице ниже. Вы можете использовать её для быстрого удаления или изменения правил. + Прочтение [[doku>acl|официальной документации по ACL]] может помочь вам в полном понимании работы управления правами доступа в «ДокуВики». diff --git a/lib/plugins/acl/lang/ru/lang.php b/lib/plugins/acl/lang/ru/lang.php index 2501c00e2..ff4740676 100644 --- a/lib/plugins/acl/lang/ru/lang.php +++ b/lib/plugins/acl/lang/ru/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Russian language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Denis Simakov <akinoame1@gmail.com> * @author Змей Этерийский evil_snake@eternion.ru * @author Hikaru Nakajima <jisatsu@mail.ru> @@ -28,7 +28,7 @@ $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>.'; $lang['p_group_id'] = 'Сейчас члены группы <b class="aclgroup">%s</b> имеют следующие права на доступ к странице <b class="aclpage">%s</b>: <i>%s</i>.'; -$lang['p_group_ns'] = 'Сейчас члены группы <b class="aclgroup">%s</b> cимеют следующие права на доступ к пространству имён <b class="aclns">%s</b>: <i>%s</i>.'; +$lang['p_group_ns'] = 'Сейчас члены группы <b class="aclgroup">%s</b> имеют следующие права на доступ к пространству имён <b class="aclns">%s</b>: <i>%s</i>.'; $lang['p_choose_id'] = 'Пожалуйста, <b>введите пользователя или группу</b> в форме выше, чтобы просмотреть или отредактировать права на доступ к странице <b class="aclpage">%s</b>.'; $lang['p_choose_ns'] = 'Пожалуйста, <b>введите пользователя или группу</b> в форме выше, чтобы просмотреть или отредактировать права на доступ к пространству имён <b class="aclns">%s</b>.'; $lang['p_inherited'] = 'Замечание: эти права доступа не были заданы явно, а были унаследованы от других групп или пространств имён более высокого порядка.'; diff --git a/lib/plugins/acl/lang/sk/lang.php b/lib/plugins/acl/lang/sk/lang.php index 398f8c63d..51837d4b4 100644 --- a/lib/plugins/acl/lang/sk/lang.php +++ b/lib/plugins/acl/lang/sk/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Slovak language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Ondrej Vegh <ov@vsieti.sk> * @author Michal Mesko <michal.mesko@gmail.com> * @author exusik@gmail.com diff --git a/lib/plugins/acl/lang/sl/lang.php b/lib/plugins/acl/lang/sl/lang.php index 44e45e491..303b18cff 100644 --- a/lib/plugins/acl/lang/sl/lang.php +++ b/lib/plugins/acl/lang/sl/lang.php @@ -1,7 +1,8 @@ <?php + /** - * Slovenian language file - * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @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/acl/lang/tr/lang.php b/lib/plugins/acl/lang/tr/lang.php index 629ca546b..a9699a5f9 100644 --- a/lib/plugins/acl/lang/tr/lang.php +++ b/lib/plugins/acl/lang/tr/lang.php @@ -1,8 +1,8 @@ <?php + /** - * turkish language file - * * @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 Cihan Kahveci <kahvecicihan@gmail.com> diff --git a/lib/plugins/acl/lang/uk/lang.php b/lib/plugins/acl/lang/uk/lang.php index 99b4b2623..97c66d8a2 100644 --- a/lib/plugins/acl/lang/uk/lang.php +++ b/lib/plugins/acl/lang/uk/lang.php @@ -1,8 +1,8 @@ <?php + /** - * ukrainian language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author Oleksiy Voronin <ovoronin@gmail.com> * @author serg_stetsuk@ukr.net * @author okunia@gmail.com diff --git a/lib/plugins/acl/lang/zh-tw/lang.php b/lib/plugins/acl/lang/zh-tw/lang.php index ff2c6a184..a56435318 100644 --- a/lib/plugins/acl/lang/zh-tw/lang.php +++ b/lib/plugins/acl/lang/zh-tw/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Chinese(Traditional) language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author chinsan <chinsan@mail2000.com.tw> * @author Li-Jiun Huang <ljhuang.tw@gmail.com> * @author http://www.chinese-tools.com/tools/converter-simptrad.html diff --git a/lib/plugins/acl/lang/zh/lang.php b/lib/plugins/acl/lang/zh/lang.php index 983882eaf..029446cca 100644 --- a/lib/plugins/acl/lang/zh/lang.php +++ b/lib/plugins/acl/lang/zh/lang.php @@ -1,8 +1,8 @@ <?php + /** - * Chinese(Simplified) language file - * * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * * @author ZDYX <zhangduyixiong@gmail.com> * @author http://www.chinese-tools.com/tools/converter-tradsimp.html * @author George Sheraton guxd@163.com diff --git a/lib/plugins/acl/remote.php b/lib/plugins/acl/remote.php index 8f6dfbcd9..6d5201cf6 100644 --- a/lib/plugins/acl/remote.php +++ b/lib/plugins/acl/remote.php @@ -16,14 +16,14 @@ class remote_plugin_acl extends DokuWiki_Remote_Plugin { ), ); } - + function addAcl($scope, $user, $level){ - $apa = plugin_load('admin', 'acl'); + $apa = plugin_load('admin', 'acl'); return $apa->_acl_add($scope, $user, $level); } - + function delAcl($scope, $user){ - $apa = plugin_load('admin', 'acl'); + $apa = plugin_load('admin', 'acl'); return $apa->_acl_del($scope, $user); } } diff --git a/lib/plugins/acl/script.js b/lib/plugins/acl/script.js index 0abb80d67..58598b1e0 100644 --- a/lib/plugins/acl/script.js +++ b/lib/plugins/acl/script.js @@ -25,9 +25,10 @@ var dw_acl = { var $frm = jQuery('#acl__detail form'); jQuery.post( - DOKU_BASE + 'lib/plugins/acl/ajax.php', + DOKU_BASE + 'lib/exe/ajax.php', jQuery.extend(dw_acl.parseatt($clicky.parent().find('a')[0].search), - {ajax: 'tree', + {call: 'plugin_acl', + ajax: 'tree', current_ns: $frm.find('input[name=ns]').val(), current_id: $frm.find('input[name=id]').val()}), show_sublist, @@ -64,8 +65,8 @@ var dw_acl = { .attr('role', 'alert') .html('<img src="'+DOKU_BASE+'lib/images/throbber.gif" alt="..." />') .load( - DOKU_BASE + 'lib/plugins/acl/ajax.php', - jQuery('#acl__detail form').serialize() + '&ajax=info' + DOKU_BASE + 'lib/exe/ajax.php', + jQuery('#acl__detail form').serialize() + '&call=plugin_acl&ajax=info' ); return false; }, diff --git a/lib/plugins/acl/style.css b/lib/plugins/acl/style.css index d8f0b53f3..a53a03450 100644 --- a/lib/plugins/acl/style.css +++ b/lib/plugins/acl/style.css @@ -1,4 +1,3 @@ - #acl__tree { font-size: 90%; width: 25%; @@ -138,4 +137,3 @@ #acl_manager table tr:hover { background-color: __background_alt__; } - |