diff options
Diffstat (limited to 'inc')
34 files changed, 666 insertions, 101 deletions
diff --git a/inc/JSON.php b/inc/JSON.php index 332827f4c..2dea44003 100644 --- a/inc/JSON.php +++ b/inc/JSON.php @@ -112,6 +112,16 @@ define('JSON_STRICT_TYPE', 11); * @deprecated */ class JSON { + + /** + * Disables the use of PHP5's native json_decode() + * + * You shouldn't change this usually because the native function is much + * faster. However, this non-native will also parse slightly broken JSON + * which might be handy when talking to a non-conform endpoint + */ + public $skipnative = false; + /** * constructs a new JSON instance * @@ -130,6 +140,7 @@ class JSON { /** * encodes an arbitrary variable into JSON format + * If available the native PHP JSON implementation is used. * * @param mixed $var any number, boolean, string, array, or object to be encoded. * see argument 1 to JSON() above for array-parsing behavior. @@ -140,6 +151,7 @@ class JSON { * @access public */ function encode($var) { + if (function_exists('json_encode')) return json_encode($var); switch (gettype($var)) { case 'boolean': return $var ? 'true' : 'false'; @@ -352,6 +364,7 @@ class JSON { /** * decodes a JSON string into appropriate variable + * If available the native PHP JSON implementation is used. * * @param string $str JSON-formatted string * @@ -363,6 +376,10 @@ class JSON { * @access public */ function decode($str) { + if (!$this->skipnative && function_exists('json_decode')){ + return json_decode($str,($this->use == JSON_LOOSE_TYPE)); + } + $str = $this->reduce_string($str); switch (strtolower($str)) { diff --git a/inc/SafeFN.class.php b/inc/SafeFN.class.php index b6e477fab..ac6698a63 100644 --- a/inc/SafeFN.class.php +++ b/inc/SafeFN.class.php @@ -114,6 +114,7 @@ class SafeFN { $converted = true; } } + if($converted) $safe .= self::$post_indicator; return $safe; } diff --git a/inc/Sitemapper.php b/inc/Sitemapper.php new file mode 100644 index 000000000..47a3fedb5 --- /dev/null +++ b/inc/Sitemapper.php @@ -0,0 +1,203 @@ +<?php +/** + * Sitemap handling functions + * + * @license GPL 2 (http://www.gnu.org/licenses/gpl.html) + * @author Michael Hamann <michael@content-space.de> + */ + +if(!defined('DOKU_INC')) die('meh.'); + +/** + * A class for building sitemaps and pinging search engines with the sitemap URL. + * + * @author Michael Hamann + */ +class Sitemapper { + /** + * Builds a Google Sitemap of all public pages known to the indexer + * + * The map is placed in the cache directory named sitemap.xml.gz - This + * file needs to be writable! + * + * @author Michael Hamann + * @author Andreas Gohr + * @link https://www.google.com/webmasters/sitemaps/docs/en/about.html + * @link http://www.sitemaps.org/ + */ + public function generate(){ + global $conf; + if($conf['sitemap'] < 1 || !is_numeric($conf['sitemap'])) return false; + + $sitemap = Sitemapper::getFilePath(); + + if(@file_exists($sitemap)){ + if(!is_writable($sitemap)) return false; + }else{ + if(!is_writable(dirname($sitemap))) return false; + } + + if(@filesize($sitemap) && + @filemtime($sitemap) > (time()-($conf['sitemap']*86400))){ // 60*60*24=86400 + dbglog('Sitemapper::generate(): Sitemap up to date'); // FIXME: only in debug mode + return false; + } + + dbglog("Sitemapper::generate(): using $sitemap"); // FIXME: Only in debug mode + + $pages = idx_getIndex('page', ''); + dbglog('Sitemapper::generate(): creating sitemap using '.count($pages).' pages'); + $items = array(); + + // build the sitemap items + foreach($pages as $id){ + //skip hidden, non existing and restricted files + if(isHiddenPage($id)) continue; + if(auth_aclcheck($id,'','') < AUTH_READ) continue; + $item = SitemapItem::createFromID($id); + if ($item !== NULL) + $items[] = $item; + } + + $eventData = array('items' => &$items, 'sitemap' => &$sitemap); + $event = new Doku_Event('SITEMAP_GENERATE', $eventData); + if ($event->advise_before(true)) { + //save the new sitemap + $result = io_saveFile($sitemap, Sitemapper::getXML($items)); + } + $event->advise_after(); + + return $result; + } + + /** + * Builds the sitemap XML string from the given array auf SitemapItems. + * + * @param $items array The SitemapItems that shall be included in the sitemap. + * @return string The sitemap XML. + * @author Michael Hamann + */ + private function getXML($items) { + ob_start(); + echo '<?xml version="1.0" encoding="UTF-8"?>'.NL; + echo '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'.NL; + foreach ($items as $item) { + echo $item->toXML(); + } + echo '</urlset>'.NL; + $result = ob_get_contents(); + ob_end_clean(); + return $result; + } + + /** + * Helper function for getting the path to the sitemap file. + * + * @return The path to the sitemap file. + * @author Michael Hamann + */ + public function getFilePath() { + global $conf; + + $sitemap = $conf['cachedir'].'/sitemap.xml'; + if($conf['compression'] === 'bz2' || $conf['compression'] === 'gz'){ + $sitemap .= '.gz'; + } + + return $sitemap; + } + + /** + * Pings search engines with the sitemap url. Plugins can add or remove + * urls to ping using the SITEMAP_PING event. + * + * @author Michael Hamann + */ + public function pingSearchEngines() { + //ping search engines... + $http = new DokuHTTPClient(); + $http->timeout = 8; + + $encoded_sitemap_url = urlencode(wl('', array('do' => 'sitemap'), true, '&')); + $ping_urls = array( + 'google' => 'http://www.google.com/webmasters/sitemaps/ping?sitemap='.$encoded_sitemap_url, + 'yahoo' => 'http://search.yahooapis.com/SiteExplorerService/V1/updateNotification?appid=dokuwiki&url='.$encoded_sitemap_url, + 'microsoft' => 'http://www.bing.com/webmaster/ping.aspx?siteMap='.$encoded_sitemap_url, + ); + + $data = array('ping_urls' => $ping_urls, + 'encoded_sitemap_url' => $encoded_sitemap_url + ); + $event = new Doku_Event('SITEMAP_PING', $data); + if ($event->advise_before(true)) { + foreach ($data['ping_urls'] as $name => $url) { + dbglog("Sitemapper::PingSearchEngines(): pinging $name"); + $resp = $http->get($url); + if($http->error) dbglog("Sitemapper:pingSearchengines(): $http->error"); + dbglog('Sitemapper:pingSearchengines(): '.preg_replace('/[\n\r]/',' ',strip_tags($resp))); + } + } + $event->advise_after(); + + return true; + } +} + +/** + * An item of a sitemap. + * + * @author Michael Hamann + */ +class SitemapItem { + public $url; + public $lastmod; + public $changefreq; + public $priority; + + /** + * Create a new item. + * + * @param $url string The url of the item + * @param $lastmod int Timestamp of the last modification + * @param $changefreq string How frequently the item is likely to change. Valid values: always, hourly, daily, weekly, monthly, yearly, never. + * @param $priority float|string The priority of the item relative to other URLs on your site. Valid values range from 0.0 to 1.0. + */ + public function __construct($url, $lastmod, $changefreq = null, $priority = null) { + $this->url = $url; + $this->lastmod = $lastmod; + $this->changefreq = $changefreq; + $this->priority = $priority; + } + + /** + * Helper function for creating an item for a wikipage id. + * + * @param $id string A wikipage id. + * @param $changefreq string How frequently the item is likely to change. Valid values: always, hourly, daily, weekly, monthly, yearly, never. + * @param $priority float|string The priority of the item relative to other URLs on your site. Valid values range from 0.0 to 1.0. + * @return The sitemap item. + */ + public static function createFromID($id, $changefreq = null, $priority = null) { + $id = trim($id); + $date = @filemtime(wikiFN($id)); + if(!$date) return NULL; + return new SitemapItem(wl($id, '', true), $date, $changefreq, $priority); + } + + /** + * Get the XML representation of the sitemap item. + * + * @return The XML representation. + */ + public function toXML() { + $result = ' <url>'.NL + .' <loc>'.hsc($this->url).'</loc>'.NL + .' <lastmod>'.date_iso8601($this->lastmod).'</lastmod>'.NL; + if ($this->changefreq !== NULL) + $result .= ' <changefreq>'.hsc($this->changefreq).'</changefreq>'.NL; + if ($this->priority !== NULL) + $result .= ' <priority>'.hsc($this->priority).'</priority>'.NL; + $result .= ' </url>'.NL; + return $result; + } +} diff --git a/inc/actions.php b/inc/actions.php index 0a6e6d8c7..9db7d5f24 100644 --- a/inc/actions.php +++ b/inc/actions.php @@ -53,6 +53,11 @@ function act_dispatch(){ //check permissions $ACT = act_permcheck($ACT); + //sitemap + if ($ACT == 'sitemap'){ + $ACT = act_sitemap($ACT); + } + //register if($ACT == 'register' && $_POST['save'] && register()){ $ACT = 'login'; @@ -205,7 +210,7 @@ function act_clean($act){ 'preview','search','show','check','index','revisions', 'diff','recent','backlink','admin','subscribe','revert', 'unsubscribe','profile','resendpwd','recover', - 'draftdel','subscribens','unsubscribens',)) && substr($act,0,7) != 'export_' ) { + 'draftdel','subscribens','unsubscribens','sitemap')) && substr($act,0,7) != 'export_' ) { msg('Command unknown: '.htmlspecialchars($act),-1); return 'show'; } @@ -233,7 +238,8 @@ function act_permcheck($act){ }else{ $permneed = AUTH_CREATE; } - }elseif(in_array($act,array('login','search','recent','profile','index'))){ + }elseif(in_array($act,array('login','search','recent','profile','index', 'sitemap'))){ + }elseif(in_array($act,array('login','search','recent','profile','sitemap'))){ $permneed = AUTH_NONE; }elseif($act == 'revert'){ $permneed = AUTH_ADMIN; @@ -587,6 +593,51 @@ function act_export($act){ } /** + * Handle sitemap delivery + * + * @author Michael Hamann <michael@content-space.de> + */ +function act_sitemap($act) { + global $conf; + + if ($conf['sitemap'] < 1 || !is_numeric($conf['sitemap'])) { + header("HTTP/1.0 404 Not Found"); + print "Sitemap generation is disabled."; + exit; + } + + $sitemap = Sitemapper::getFilePath(); + if(strrchr($sitemap, '.') === '.gz'){ + $mime = 'application/x-gzip'; + }else{ + $mime = 'application/xml; charset=utf-8'; + } + + // Check if sitemap file exists, otherwise create it + if (!is_readable($sitemap)) { + Sitemapper::generate(); + } + + if (is_readable($sitemap)) { + // Send headers + header('Content-Type: '.$mime); + + http_conditionalRequest(filemtime($sitemap)); + + // Send file + //use x-sendfile header to pass the delivery to compatible webservers + if (http_sendfile($sitemap)) exit; + + readfile($sitemap); + exit; + } + + header("HTTP/1.0 500 Internal Server Error"); + print "Could not read the sitemap file - bad permissions?"; + exit; +} + +/** * Handle page 'subscribe' * * Throws exception on error. diff --git a/inc/changelog.php b/inc/changelog.php index bb00df76c..cc7612bfd 100644 --- a/inc/changelog.php +++ b/inc/changelog.php @@ -37,6 +37,15 @@ function parseChangelogLine($line) { /** * Add's an entry to the changelog and saves the metadata for the page * + * @param int $date Timestamp of the change + * @param String $id Name of the affected page + * @param String $type Type of the change see DOKU_CHANGE_TYPE_* + * @param String $summary Summary of the change + * @param mixed $extra In case of a revert the revision (timestmp) of the reverted page + * @param array $flags Additional flags in a key value array. + * Availible flags: + * - ExternalEdit - mark as an external edit. + * * @author Andreas Gohr <andi@splitbrain.org> * @author Esther Brunner <wikidesign@gmail.com> * @author Ben Coburn <btcoburn@silicodon.net> diff --git a/inc/common.php b/inc/common.php index 3e760419f..18f782788 100644 --- a/inc/common.php +++ b/inc/common.php @@ -1134,12 +1134,7 @@ function notify($id,$who,$rev='',$summary='',$minor=false,$replace=array()){ $subject = '['.utf8_substr($conf['title'], 0, 20).'...] '.$subject; } - $from = $conf['mailfrom']; - $from = str_replace('@USER@',$_SERVER['REMOTE_USER'],$from); - $from = str_replace('@NAME@',$INFO['userinfo']['name'],$from); - $from = str_replace('@MAIL@',$INFO['userinfo']['mail'],$from); - - mail_send($to,$subject,$text,$from,'',$bcc); + mail_send($to,$subject,$text,$conf['mailfrom'],'',$bcc); } /** @@ -1271,6 +1266,21 @@ function dformat($dt=null,$format=''){ } /** + * Formats a timestamp as ISO 8601 date + * + * @author <ungu at terong dot com> + * @link http://www.php.net/manual/en/function.date.php#54072 + */ +function date_iso8601($int_date) { + //$int_date: current date in UNIX timestamp + $date_mod = date('Y-m-d\TH:i:s', $int_date); + $pre_timezone = date('O', $int_date); + $time_zone = substr($pre_timezone, 0, 3).":".substr($pre_timezone, 3, 2); + $date_mod .= $time_zone; + return $date_mod; +} + +/** * return an obfuscated email address in line with $conf['mailguard'] setting * * @author Harry Fuecks <hfuecks@gmail.com> diff --git a/inc/fulltext.php b/inc/fulltext.php index 943a5d401..7ace3a724 100644 --- a/inc/fulltext.php +++ b/inc/fulltext.php @@ -229,6 +229,7 @@ function ft_pageLookup($id, $in_ns=false, $in_title=false){ } function _ft_pageLookup(&$data){ + global $conf; // split out original parameters $id = $data['id']; if (preg_match('/(?:^| )@(\w+)/', $id, $matches)) { @@ -241,6 +242,11 @@ function _ft_pageLookup(&$data){ $pages = array_map('rtrim', idx_getIndex('page', '')); $titles = array_map('rtrim', idx_getIndex('title', '')); + // check for corrupt title index #FS2076 + if(count($pages) != count($titles)){ + $titles = array_fill(0,count($pages),''); + @unlink($conf['indexdir'].'/title.idx'); // will be rebuilt in inc/init.php + } $pages = array_combine($pages, $titles); $cleaned = cleanID($id); @@ -270,7 +276,7 @@ function _ft_pageLookup(&$data){ } } - uasort($pages,'ft_pagesorter'); + uksort($pages,'ft_pagesorter'); return $pages; } diff --git a/inc/html.php b/inc/html.php index a02cc020d..9d3c92707 100644 --- a/inc/html.php +++ b/inc/html.php @@ -163,11 +163,12 @@ function html_topbtn(){ * * @author Andreas Gohr <andi@splitbrain.org> */ -function html_btn($name,$id,$akey,$params,$method='get',$tooltip=''){ +function html_btn($name,$id,$akey,$params,$method='get',$tooltip='',$label=false){ global $conf; global $lang; - $label = $lang['btn_'.$name]; + if (!$label) + $label = $lang['btn_'.$name]; $ret = ''; $tip = ''; diff --git a/inc/init.php b/inc/init.php index bf7815178..ed4409729 100644 --- a/inc/init.php +++ b/inc/init.php @@ -220,6 +220,9 @@ if (!defined('NOSESSION')) { auth_setup(); } +// setup mail system +mail_setup(); + /** * Checks paths from config file */ diff --git a/inc/lang/cs/lang.php b/inc/lang/cs/lang.php index 33c6db01a..749a41a5b 100644 --- a/inc/lang/cs/lang.php +++ b/inc/lang/cs/lang.php @@ -242,7 +242,7 @@ $lang['i_wikiname'] = 'Název wiki'; $lang['i_enableacl'] = 'Zapnout ACL (doporučeno)'; $lang['i_superuser'] = 'Správce'; $lang['i_problems'] = 'Instalátor narazil na níže popsané problémy. Nelze pokračovat v instalaci, dokud je neopravíte.'; -$lang['i_modified'] = 'Instalátor bude z bezpečnostních důvodů pracovat pouze s čistou a ještě neupravenou instalací DokuWiki. Buď znovu rozbalte souboru z instalačního balíčku nebo se zkuste poradit s <a href="http://dokuwiki.org/install">instrukcemi pro instalci DokuWiki</a>.'; +$lang['i_modified'] = 'Instalátor bude z bezpečnostních důvodů pracovat pouze s čistou a ještě neupravenou instalací DokuWiki. Buď znovu rozbalte souboru z instalačního balíčku nebo se zkuste poradit s <a href="http://dokuwiki.org/install">instrukcemi pro instalaci DokuWiki</a>.'; $lang['i_funcna'] = 'PHP funkce <code>%s</code> není dostupná. Váš webhosting ji možná z nějakého důvodu vypnul.'; $lang['i_phpver'] = 'Verze vaší instalace PHP <code>%s</code> je nižší než požadovaná <code>%s</code>. Budete muset aktualizovat svou instalaci PHP.'; $lang['i_permfail'] = 'DokuWiki nemůže zapisovat do <code>%s</code>. Budete muset opravit práva k tomuto adresáři.'; @@ -268,7 +268,7 @@ $lang['mu_toobig'] = 'příliš velké'; $lang['mu_ready'] = 'připraveno k načtení'; $lang['mu_done'] = 'hotovo'; $lang['mu_fail'] = 'selhalo'; -$lang['mu_authfail'] = 'vypršla session'; +$lang['mu_authfail'] = 'vypršela session'; $lang['mu_progress'] = '@PCT@% načten'; $lang['mu_filetypes'] = 'Povolené typy souborů'; $lang['mu_info'] = 'soubory načteny.'; diff --git a/inc/lang/cs/subscr_form.txt b/inc/lang/cs/subscr_form.txt index b786ac137..d051b646f 100644 --- a/inc/lang/cs/subscr_form.txt +++ b/inc/lang/cs/subscr_form.txt @@ -1,3 +1,3 @@ ====== Správa odběratelů změn ====== -Tato stránka Vám umožnuje spravovat uživatele přihlášené k odběru změn aktuální stránky nebo jmenného prostoru.
\ No newline at end of file +Tato stránka Vám umožňuje spravovat uživatele přihlášené k odběru změn aktuální stránky nebo jmenného prostoru.
\ No newline at end of file diff --git a/inc/lang/de-informal/draft.txt b/inc/lang/de-informal/draft.txt index 704c6d1da..e56dbe083 100644 --- a/inc/lang/de-informal/draft.txt +++ b/inc/lang/de-informal/draft.txt @@ -2,5 +2,5 @@ Deine letzte Bearbeitungssitzung wurde nicht ordnungsgemäß abgeschlossen. DokuWiki hat während deiner Arbeit automatisch einen Zwischenentwurf gespeichert, den du jetzt nutzen kannst, um deine Arbeit fortzusetzen. Unten siehst du die Daten, die bei deiner letzten Sitzung gespeichert wurden. -Bitte entscheide dich, ob du den Entwurf //wieder herstellen// oder //löschen// willst oder ob du die Bearbeitung abbrechen möchtest. +Bitte entscheide dich, ob du den Entwurf //wiederherstellen// oder //löschen// willst oder ob du die Bearbeitung abbrechen möchtest. diff --git a/inc/lang/de/draft.txt b/inc/lang/de/draft.txt index 14a5e8495..77a55b165 100644 --- a/inc/lang/de/draft.txt +++ b/inc/lang/de/draft.txt @@ -2,5 +2,5 @@ Ihre letzte Bearbeitungssitzung wurde nicht ordnungsgemäß abgeschlossen. DokuWiki hat während Ihrer Arbeit automatisch einen Zwischenentwurf gespeichert, den Sie jetzt nutzen können, um Ihre Arbeit fortzusetzen. Unten sehen Sie die Daten, die bei Ihrer letzten Sitzung gespeichert wurden. -Bitte entscheiden Sie, ob Sie den Entwurf //wieder herstellen// oder //löschen// wollen oder ob Sie die Bearbeitung abbrechen möchten. +Bitte entscheiden Sie, ob Sie den Entwurf //wiederherstellen// oder //löschen// wollen oder ob Sie die Bearbeitung abbrechen möchten. diff --git a/inc/lang/eu/adminplugins.txt b/inc/lang/eu/adminplugins.txt new file mode 100644 index 000000000..20709bfd6 --- /dev/null +++ b/inc/lang/eu/adminplugins.txt @@ -0,0 +1 @@ +===== Plugin Gehigarriak =====
\ No newline at end of file diff --git a/inc/lang/eu/lang.php b/inc/lang/eu/lang.php index a5f786654..2efec00be 100644 --- a/inc/lang/eu/lang.php +++ b/inc/lang/eu/lang.php @@ -38,15 +38,13 @@ $lang['btn_back'] = 'Atzera'; $lang['btn_backlink'] = 'Itzulera estekak'; $lang['btn_backtomedia'] = 'Atzera Multimedia Fitxategiaren Aukeraketara'; $lang['btn_subscribe'] = 'Harpidetu Orri Aldaketetara'; -$lang['btn_unsubscribe'] = 'Utzi Harpidetza Orri Aldaketetara'; -$lang['btn_subscribens'] = 'Harpidetu Izen-espazio Aldaketetara'; -$lang['btn_unsubscribens'] = 'Utzi Harpidetza Izen-espazio Aldaketetara'; $lang['btn_profile'] = 'Eguneratu Profila '; $lang['btn_reset'] = 'Aldaketak Desegin'; $lang['btn_resendpwd'] = 'Pasahitz berria bidali'; $lang['btn_draft'] = 'Editatu zirriborroa'; $lang['btn_recover'] = 'Berreskuratu zirriborroa'; $lang['btn_draftdel'] = 'Ezabatu zirriborroa'; +$lang['btn_revert'] = 'Berrezarri'; $lang['loggedinas'] = 'Erabiltzailea'; $lang['user'] = 'Erabiltzailea'; $lang['pass'] = 'Pasahitza'; @@ -85,13 +83,46 @@ $lang['resendpwdconfirm'] = 'Baieztapen esteka bat e-postaz bidali da.'; $lang['resendpwdsuccess'] = 'Zure pasahitz berria e-postaz bidali da.'; $lang['license'] = 'Besterik esan ezean, wiki hontako edukia ondorengo lizentziapean argitaratzen da:'; $lang['licenseok'] = 'Oharra: Orri hau editatzean, zure edukia ondorengo lizentziapean argitaratzea onartzen duzu: '; +$lang['searchmedia'] = 'Bilatu fitxategi izena:'; +$lang['searchmedia_in'] = 'Bilatu %s-n'; $lang['txt_upload'] = 'Ireki nahi den fitxategia aukeratu'; $lang['txt_filename'] = 'Idatzi wikiname-a (aukerazkoa)'; $lang['txt_overwrt'] = 'Oraingo fitxategiaren gainean idatzi'; $lang['lockedby'] = 'Momentu honetan blokeatzen:'; $lang['lockexpire'] = 'Blokeaketa iraungitzen da:'; $lang['willexpire'] = 'Zure blokeaketa orri hau aldatzeko minutu batean iraungitzen da.\nGatazkak saihesteko, aurreikusi botoia erabili blokeaketa denboragailua berrabiarazteko.'; -$lang['js']['notsavedyet'] = "Gorde gabeko aldaketak galdu egingo dira.\nBenetan jarraitu nahi duzu?"; +$lang['js']['notsavedyet'] = 'Gorde gabeko aldaketak galdu egingo dira. +Benetan jarraitu nahi duzu?'; +$lang['js']['searchmedia'] = 'Bilatu fitxategiak'; +$lang['js']['keepopen'] = 'Mantendu leihoa irekita aukeraketan'; +$lang['js']['hidedetails'] = 'Xehetasunak Ezkutatu'; +$lang['js']['mediatitle'] = 'Esteken ezarpenak'; +$lang['js']['mediadisplay'] = 'Esteka mota'; +$lang['js']['mediaalign'] = 'Lerrokatzea'; +$lang['js']['mediasize'] = 'Irudi tamaina'; +$lang['js']['mediatarget'] = 'Estekaren helburua'; +$lang['js']['mediaclose'] = 'Itxi'; +$lang['js']['mediainsert'] = 'Txertatu'; +$lang['js']['mediadisplayimg'] = 'Irudia erakutsi'; +$lang['js']['mediadisplaylnk'] = 'Esteka bakarrik erakutsi'; +$lang['js']['mediasmall'] = 'Bertsio txikia'; +$lang['js']['mediamedium'] = 'Bertsio ertaina'; +$lang['js']['medialarge'] = 'Bertsio handia'; +$lang['js']['mediaoriginal'] = 'Jatorrizko bertsioa'; +$lang['js']['medialnk'] = 'Esteka xehetasunen orrira'; +$lang['js']['mediadirect'] = 'Jatorrizkora esteka zuzena'; +$lang['js']['medianolnk'] = 'Estekarik ez'; +$lang['js']['medianolink'] = 'Ez estekatu irudia'; +$lang['js']['medialeft'] = 'Irudia ezkerrean lerrokatu'; +$lang['js']['mediaright'] = 'Irudia eskuinean lerrokatu'; +$lang['js']['mediacenter'] = 'Irudia erdian lerrokatu'; +$lang['js']['medianoalign'] = 'Ez erabili lerrokatzerik'; +$lang['js']['nosmblinks'] = 'Window baliabide konpartituetara estekek Microsoft Internet Explorer-en bakarrik balio dute. +Esteka kopiatu eta itsatsi dezakezu dena den.'; +$lang['js']['linkwiz'] = 'Estekatze Laguntzailea'; +$lang['js']['linkto'] = 'Estekatu hona:'; +$lang['js']['del_confirm'] = 'Benetan ezabatu aukeratutako fitxategia(k)?'; +$lang['js']['mu_btn'] = 'Igo hainbat fitxategi aldi berean'; $lang['rssfailed'] = 'Errorea gertatu da feed hau irakurtzean:'; $lang['nothingfound'] = 'Ez da ezer aurkitu.'; $lang['mediaselect'] = 'Aukeratu Multimedia fitxategia'; @@ -109,11 +140,7 @@ $lang['deletefail'] = 'Ezin izan da "%s" ezabatu - egiaztatu baimenak $lang['mediainuse'] = 'Ez da "%s" fitxategia ezabatu - oraindik erabilia izaten ari da.'; $lang['namespaces'] = 'Izen-espazioak'; $lang['mediafiles'] = 'Fitxategiak eskuragarri hemen:'; -$lang['js']['keepopen'] = 'Mantendu leihoa irekita aukeraketan'; -$lang['js']['hidedetails'] = 'Xehetasunak Ezkutatu'; -$lang['js']['nosmblinks'] = 'Window baliabide konpartituetara estekek Microsoft Internet Explorer-en bakarrik balio dute. -Esteka kopiatu eta itsatsi dezakezu dena den.'; -$lang['js']['mu_btn'] = 'Igo hainbat fitxategi aldi berean'; +$lang['accessdenied'] = 'Ez zaude orri hau ikusteko baimendua'; $lang['mediausage'] = 'Erabili ondoko sintaxia fitxategi honi erreferentzia egiteko:'; $lang['mediaview'] = 'Ikusi jatorrizko fitxategia'; $lang['mediaroot'] = 'root'; @@ -129,6 +156,7 @@ $lang['current'] = 'egungoa'; $lang['yours'] = 'Zure Bertsioa'; $lang['diff'] = 'egungo bertsioarekin dituen aldaketak aurkezten ditu'; $lang['diff2'] = 'Erakutsi desberdintasunak aukeratutako bertsioen artean'; +$lang['difflink'] = 'Estekatu konparaketa bista honetara'; $lang['line'] = 'Marra'; $lang['breadcrumb'] = 'Traza'; $lang['youarehere'] = 'Hemen zaude'; @@ -140,8 +168,10 @@ $lang['restored'] = 'bertsio zaharra berrezarria'; $lang['external_edit'] = 'kanpoko aldaketa'; $lang['summary'] = 'Aldatu laburpena'; $lang['noflash'] = '<a href="http://www.adobe.com/products/flashplayer/">Adobe Flash Plugin</a> beharrezkoa da eduki hau bistaratzeko.'; +$lang['download'] = 'Deskarga Snippet-a'; $lang['mail_newpage'] = '[DokuWiki] gehitutako orria:'; $lang['mail_changed'] = '[DokuWiki] aldatutako orria:'; +$lang['mail_subscribe_list'] = 'izen-espazioan aldatutako orriak:'; $lang['mail_new_user'] = 'erabiltzaile berria:'; $lang['mail_upload'] = 'fitxategia igota:'; $lang['qb_bold'] = 'Letra beltzez'; @@ -154,6 +184,11 @@ $lang['qb_h2'] = 'Izenburua 2'; $lang['qb_h3'] = 'Izenburua 3'; $lang['qb_h4'] = 'Izenburua 4'; $lang['qb_h5'] = 'Izenburua 5'; +$lang['qb_h'] = 'Izenburua'; +$lang['qb_hs'] = 'Izenburua Aukeratu'; +$lang['qb_hplus'] = 'Izenburu Handiagoa'; +$lang['qb_hminus'] = 'Izenburu Txikiagoa'; +$lang['qb_hequal'] = 'Maila Berdineko Izenburua'; $lang['qb_link'] = 'Barruko Lotura'; $lang['qb_extlink'] = 'Kanpoko Lotura'; $lang['qb_hr'] = 'Horizontal Marra'; @@ -163,7 +198,7 @@ $lang['qb_media'] = 'Irudiak eta beste fitxategiak gehitu'; $lang['qb_sig'] = 'Gehitu sinadura'; $lang['qb_smileys'] = 'Irrifartxoak'; $lang['qb_chars'] = 'Karaktere Bereziak'; -$lang['js']['del_confirm'] = 'Benetan ezabatu aukeratutako fitxategia(k)?'; +$lang['upperns'] = 'Jauzi izen-espazio gurasora'; $lang['admin_register'] = 'Erabiltzaile berria gehitu'; $lang['metaedit'] = 'Metadatua Aldatu'; $lang['metasaveerr'] = 'Metadatuaren idazketak huts egin du'; @@ -179,11 +214,22 @@ $lang['img_copyr'] = 'Copyright'; $lang['img_format'] = 'Formatua'; $lang['img_camera'] = 'Kamera'; $lang['img_keywords'] = 'Hitz-gakoak'; -$lang['subscribe_success'] = 'Gehitua %s %s harpidetza zerrendara'; -$lang['subscribe_error'] = 'Errorea %s gehitzen %s harpidetza zerrendara'; -$lang['subscribe_noaddress'] = 'Ez dago posta elektroniko helbiderik zure erabiltzaile izenarekin erlazionatuta, ezin zara harpidetza zerrendara gehitua izan'; -$lang['unsubscribe_success'] = 'Ezabatua %s %s harpidetza zerrendatik'; -$lang['unsubscribe_error'] = 'Errorea %s ezabatzen %s harpidetza zerrendatik'; +$lang['subscr_subscribe_success'] = '%s gehitua %s-ren harpidetza zerrendara'; +$lang['subscr_subscribe_error'] = 'Errorea %s gehitzen %s-ren harpidetza zerrendara'; +$lang['subscr_subscribe_noaddress'] = 'Ez dago helbiderik zure login-arekin lotuta, ezin zara harpidetza zerrendara gehitua izan.'; +$lang['subscr_unsubscribe_success'] = '%s ezabatua %s-ren harpidetza zerrendatik'; +$lang['subscr_unsubscribe_error'] = 'Errorea %s ezabatzen %s-ren harpidetza zerrendatik'; +$lang['subscr_already_subscribed'] = '%s lehendik harpidetua dago %s-n'; +$lang['subscr_not_subscribed'] = '%s ez dago %s-n harpidetua'; +$lang['subscr_m_not_subscribed'] = 'Momentu honetan ez zaude orri honetara edo izen-espazio honetara harpidetua.'; +$lang['subscr_m_new_header'] = 'Gehitu harpidetza'; +$lang['subscr_m_current_header'] = 'Uneko harpidetzak'; +$lang['subscr_m_unsubscribe'] = 'Kendu harpidetza'; +$lang['subscr_m_subscribe'] = 'Harpidetu'; +$lang['subscr_m_receive'] = 'Jaso'; +$lang['subscr_style_every'] = 'e-posta aldaketa bakoitzean'; +$lang['subscr_style_digest'] = 'e-posta laburbildua orri bakoitzeko aldaketentzat (%.2f egunero)'; +$lang['subscr_style_list'] = 'aldatutako orrien zerrenda azken e-postatik (%.2f egunero)'; $lang['authmodfailed'] = 'Erabiltzaile kautotzearen konfigurazioa okerra da. Mesedez, eman honen berri Wiki administratzaileari'; $lang['authtempfail'] = 'Erabiltzaile kautotzea denboraldi batez ez dago erabilgarri. Egoerak hala jarraitzen badu, mesedez, eman honen berri Wiki administratzaileari'; $lang['i_chooselang'] = 'Hautatu zure hizkuntza'; @@ -207,6 +253,7 @@ $lang['i_pol0'] = 'Wiki Irekia (irakurri, idatzi, fitxategiak igo $lang['i_pol1'] = 'Wiki Publikoa (irakurri edonorentzat, idatzi eta fitxategiak igo erregistratutako erabiltzaileentzat)'; $lang['i_pol2'] = 'Wiki Itxia (irakurri, idatzi, fitxategiak igo erregistratutako erabiltzaileentzat soilik)'; $lang['i_retry'] = 'Berriz saiatu'; +$lang['i_license'] = 'Mesedez, aukeratu zein lizentzipean ezarri nahi duzun zure edukia:'; $lang['mu_intro'] = 'Hemen hainbat fitxategi aldi berean igo ditzakezu. Egin klik nabigazio botoian hauek ilarara gehitzeko. Sakatu igo botoia prest egotean.'; $lang['mu_gridname'] = 'Fitxategi izena'; $lang['mu_gridsize'] = 'Tamaina'; @@ -220,4 +267,14 @@ $lang['mu_fail'] = 'hutsegitea'; $lang['mu_authfail'] = 'saioa iraungita'; $lang['mu_progress'] = '@PCT@% igota'; $lang['mu_filetypes'] = 'Onartutako Fitxategi Motak'; +$lang['mu_info'] = 'igotako fitxategiak.'; +$lang['mu_lasterr'] = 'Azken errorea;'; $lang['recent_global'] = 'Une honetan <b>%s</b> izen-espazioaren barneko aldaketak ikusten ari zara.<a href="%s"> Wiki osoaren azken aldaketak</a> ere ikusi ditzakezu.'; +$lang['years'] = 'duela %d urte'; +$lang['months'] = 'duela %d hilabete'; +$lang['weeks'] = 'duela %d aste'; +$lang['days'] = 'duela %d egun'; +$lang['hours'] = 'duela %d ordu'; +$lang['minutes'] = 'duela %d minutu'; +$lang['seconds'] = 'duela %d segundu'; +$lang['wordblock'] = 'Zure aldaketa ez da aldatua izan blokeatutako testua (spam) daukalako.'; diff --git a/inc/lang/eu/subscr_digest.txt b/inc/lang/eu/subscr_digest.txt new file mode 100644 index 000000000..e7962ca22 --- /dev/null +++ b/inc/lang/eu/subscr_digest.txt @@ -0,0 +1,20 @@ +Kaixo! + +@TITLE@ wikiko @PAGE@ orria aldatu egin da. +Hemen aldaketak: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +Berrikuste zaharra: @OLDPAGE@ +Berrikuste berria: @NEWPAGE@ + +Orri jakinarazpenak ezeztatzeko, sartu wikian +@DOKUWIKIURL@ helbidean, bisitatu +@SUBSCRIBE@ +eta ezabatu orri eta/edo izen-espazio aldaketen harpidetza. + +-- +E-posta hau DokuWiki-k sortua izan da helbide honetan: +@DOKUWIKIURL@
\ No newline at end of file diff --git a/inc/lang/eu/subscr_form.txt b/inc/lang/eu/subscr_form.txt new file mode 100644 index 000000000..02a117898 --- /dev/null +++ b/inc/lang/eu/subscr_form.txt @@ -0,0 +1,3 @@ +====== Harpidetza Kudeaketa ====== + +Orri honek, oraingo orriko eta izen-espazioko harpidetzak kudeatzeko aukera ematen dizu.
\ No newline at end of file diff --git a/inc/lang/eu/subscr_list.txt b/inc/lang/eu/subscr_list.txt new file mode 100644 index 000000000..950cd352b --- /dev/null +++ b/inc/lang/eu/subscr_list.txt @@ -0,0 +1,17 @@ +Kaixo! + +@TITLE@ wikiko @PAGE@ izen-espazioko orri batzuk aldatu egin dira. +Hemen aldatutako orriak: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +Orri jakinarazpenak ezeztatzeko, sartu wikian +@DOKUWIKIURL@ helbidean, bisitatu +@SUBSCRIBE@ +eta ezabatu orri eta/edo izen-espazio aldaketen harpidetza. + +-- +E-posta hau DokuWiki-k sortua izan da helbide honetan: +@DOKUWIKIURL@
\ No newline at end of file diff --git a/inc/lang/eu/subscr_single.txt b/inc/lang/eu/subscr_single.txt new file mode 100644 index 000000000..490211784 --- /dev/null +++ b/inc/lang/eu/subscr_single.txt @@ -0,0 +1,23 @@ +Kaixo! + +@TITLE@ wikiko @PAGE@ orria aldatu egin da. +Hemen aldaketak: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +Data : @DATE@ +Erabiltzailea : @USER@ +Aldaketaren Laburpena: @SUMMARY@ +Berrikuste Zaharra: @OLDPAGE@ +Berrikuste Berria: @NEWPAGE@ + +Orri jakinarazpenak ezeztatzeko, sartu wikian +@DOKUWIKIURL@ helbidean, bisitatu +@SUBSCRIBE@ +eta ezabatu orri eta/edo izen-espazio aldaketen harpidetza. + +-- +E-posta hau DokuWiki-k sortua izan da helbide honetan: +@DOKUWIKIURL@
\ No newline at end of file diff --git a/inc/lang/ko/adminplugins.txt b/inc/lang/ko/adminplugins.txt new file mode 100644 index 000000000..5312cf357 --- /dev/null +++ b/inc/lang/ko/adminplugins.txt @@ -0,0 +1 @@ +===== 부가적인 플러그인 =====
\ No newline at end of file diff --git a/inc/lang/ko/edit.txt b/inc/lang/ko/edit.txt index d73f935fe..9b59524f7 100644 --- a/inc/lang/ko/edit.txt +++ b/inc/lang/ko/edit.txt @@ -1,2 +1,2 @@ -페이지를 편집하고 **저장**을 누르십시오. 위키 구문은 [[wiki:syntax]] 혹은 [[syntax|(한글) 구문]]을 참고하십시오. 이 페이지를 **더 낫게 만들 자신이 있을** 때에만 편집하십시오. 실험을 하고 싶을 때에는, 먼저 [[playground:playground|연습장]] 에 가서 연습해 보십시오. +페이지를 편집하고 **저장**을 누르십시오. 위키 구문은 [[wiki:syntax]] 혹은 [[wiki:ko_syntax|(한글) 구문]]을 참고하십시오. 이 페이지를 **더 낫게 만들 자신이 있을** 때에만 편집하십시오. 실험을 하고 싶을 때에는, 먼저 [[playground:playground|연습장]] 에 가서 연습해 보십시오. diff --git a/inc/lang/ko/lang.php b/inc/lang/ko/lang.php index 83014c151..3765dd011 100644 --- a/inc/lang/ko/lang.php +++ b/inc/lang/ko/lang.php @@ -8,6 +8,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['encoding'] = 'utf-8'; $lang['direction'] = 'ltr'; @@ -41,15 +42,13 @@ $lang['btn_back'] = '뒤로'; $lang['btn_backlink'] = '이전 링크'; $lang['btn_backtomedia'] = '미디어 파일 선택으로 돌아가기'; $lang['btn_subscribe'] = '구독 신청'; -$lang['btn_unsubscribe'] = '구독 신청 해지'; -$lang['btn_subscribens'] = '네임스페이스 구독 신청'; -$lang['btn_unsubscribens'] = '네임스페이스 구독 신청 해지'; $lang['btn_profile'] = '개인정보 변경'; $lang['btn_reset'] = '초기화'; $lang['btn_resendpwd'] = '새 패스워드 보내기'; $lang['btn_draft'] = '문서초안 편집'; $lang['btn_recover'] = '문서초안 복구'; $lang['btn_draftdel'] = '문서초안 삭제'; +$lang['btn_revert'] = '복원'; $lang['loggedinas'] = '다음 사용자로 로그인'; $lang['user'] = '사용자'; $lang['pass'] = '패스워드'; @@ -88,13 +87,45 @@ $lang['resendpwdconfirm'] = '확인 링크를 이메일로 보냈습니다. $lang['resendpwdsuccess'] = '새로운 패스워드는 이메일로 보내드립니다.'; $lang['license'] = '이 위키의 내용은 다음의 라이센스에 따릅니다 :'; $lang['licenseok'] = '주의 : 이 페이지를 수정한다는 다음의 라이센스에 동의함을 의미합니다 :'; +$lang['searchmedia'] = '파일이름 찾기:'; +$lang['searchmedia_in'] = ' %에서 검색'; $lang['txt_upload'] = '업로드 파일을 선택합니다.'; $lang['txt_filename'] = '업로드 파일 이름을 입력합니다.(선택 사항)'; $lang['txt_overwrt'] = '새로운 파일로 이전 파일을 교체합니다.'; $lang['lockedby'] = '현재 잠금 사용자'; $lang['lockexpire'] = '잠금 해제 시간'; $lang['willexpire'] = '잠시 후 편집 잠금이 해제됩니다.\n편집 충돌을 피하려면 미리보기를 눌러 잠금 시간을 다시 설정하기 바랍니다.'; -$lang['js']['notsavedyet'] = "저장하지 않은 변경은 지워집니다.\n계속하시겠습니까?"; +$lang['js']['notsavedyet'] = '저장하지 않은 변경은 지워집니다. +계속하시겠습니까?'; +$lang['js']['searchmedia'] = '파일 찾기'; +$lang['js']['keepopen'] = '선택할 때 윈도우를 열어놓으시기 바랍니다.'; +$lang['js']['hidedetails'] = '자세한 정보 감추기'; +$lang['js']['mediatitle'] = '링크 설정'; +$lang['js']['mediadisplay'] = '링크 형태'; +$lang['js']['mediaalign'] = '배치'; +$lang['js']['mediasize'] = '그림 크기'; +$lang['js']['mediatarget'] = '링크 목표'; +$lang['js']['mediaclose'] = '닫기'; +$lang['js']['mediainsert'] = '삽입'; +$lang['js']['mediadisplayimg'] = '그림보기'; +$lang['js']['mediasmall'] = '작게'; +$lang['js']['mediamedium'] = '중간'; +$lang['js']['medialarge'] = '크게'; +$lang['js']['mediaoriginal'] = '원본'; +$lang['js']['medialnk'] = '세부정보페이지로 링크'; +$lang['js']['mediadirect'] = '원본으로 직접 링크'; +$lang['js']['medianolnk'] = '링크 없슴'; +$lang['js']['medianolink'] = '그림을 링크하지 않음'; +$lang['js']['medialeft'] = '왼쪽 배치'; +$lang['js']['mediaright'] = '오른쪽 배치'; +$lang['js']['mediacenter'] = '중앙 배치'; +$lang['js']['medianoalign'] = '배치 없슴'; +$lang['js']['nosmblinks'] = '윈도우 공유 파일과의 연결은 MS 인터넷 익스플로러에서만 동작합니다. +그러나 링크를 복사하거나 붙여넣기를 할 수 있습니다.'; +$lang['js']['linkwiz'] = '링크 마법사'; +$lang['js']['linkto'] = '다음으로 연결:'; +$lang['js']['del_confirm'] = '정말로 선택된 항목(들)을 삭제하시겠습니까?'; +$lang['js']['mu_btn'] = '여러 파일들을 한번에 업로드합니다.'; $lang['rssfailed'] = 'feed 가져오기 실패: '; $lang['nothingfound'] = '아무 것도 없습니다.'; $lang['mediaselect'] = '미디어 파일 선택'; @@ -112,11 +143,7 @@ $lang['deletefail'] = '"%s" 파일을 삭제할 수 없습니다. - $lang['mediainuse'] = '"%s" 파일을 삭제할 수 없습니다. - 아직 사용 중입니다.'; $lang['namespaces'] = '네임스페이스'; $lang['mediafiles'] = '사용 가능한 파일 목록'; -$lang['js']['keepopen'] = '선택할 때 윈도우를 열어놓으시기 바랍니다.'; -$lang['js']['hidedetails'] = '자세한 정보 감추기'; -$lang['js']['nosmblinks'] = '윈도우 공유 파일과의 연결은 MS 인터넷 익스플로러에서만 동작합니다. -그러나 링크를 복사하거나 붙여넣기를 할 수 있습니다.'; -$lang['js']['mu_btn'] = '여러 파일들을 한번에 업로드합니다.'; +$lang['accessdenied'] = '이 페이지를 볼 권한이 없습니다.'; $lang['mediausage'] = '이 파일을 참조하려면 다음 문법을 사용하기 바랍니다:'; $lang['mediaview'] = '원본 파일 보기'; $lang['mediaroot'] = '루트(root)'; @@ -143,8 +170,10 @@ $lang['restored'] = '옛 버전 복구'; $lang['external_edit'] = '외부 편집기'; $lang['summary'] = '편집 요약'; $lang['noflash'] = '이 컨텐츠를 표시하기 위해서 <a href="http://www.adobe.com/products/flashplayer/">Adobe Flash Plugin</a>이 필요합니다.'; +$lang['download'] = '조각 다운로드'; $lang['mail_newpage'] = '페이지 추가:'; $lang['mail_changed'] = '페이지 변경:'; +$lang['mail_subscribe_list'] = '네임스페이스에서 변경된 페이지:'; $lang['mail_new_user'] = '새로운 사용자:'; $lang['mail_upload'] = '파일 첨부:'; $lang['qb_bold'] = '굵은 글'; @@ -157,6 +186,11 @@ $lang['qb_h2'] = '2단계 헤드라인'; $lang['qb_h3'] = '3단계 헤드라인'; $lang['qb_h4'] = '4단계 헤드라인'; $lang['qb_h5'] = '5단계 헤드라인'; +$lang['qb_h'] = '표제'; +$lang['qb_hs'] = '표제 선택'; +$lang['qb_hplus'] = '상위 표제'; +$lang['qb_hminus'] = '하위 표제'; +$lang['qb_hequal'] = '동급 표제'; $lang['qb_link'] = '내부 링크'; $lang['qb_extlink'] = '외부 링크'; $lang['qb_hr'] = '수평선'; @@ -166,7 +200,7 @@ $lang['qb_media'] = '이미지와 기타 파일 추가'; $lang['qb_sig'] = '서명 추가'; $lang['qb_smileys'] = '이모티콘'; $lang['qb_chars'] = '특수문자'; -$lang['js']['del_confirm'] = '정말로 선택된 항목(들)을 삭제하시겠습니까?'; +$lang['upperns'] = '상위 네임스페이스로 이동'; $lang['admin_register'] = '새로운 사용자 추가'; $lang['metaedit'] = '메타 데이타를 편집합니다.'; $lang['metasaveerr'] = '메타 데이타 쓰기가 실패했습니다.'; @@ -182,11 +216,16 @@ $lang['img_copyr'] = '저작권'; $lang['img_format'] = '포맷'; $lang['img_camera'] = '카메라'; $lang['img_keywords'] = '키워드'; -$lang['subscribe_success'] = '%s를 추가했습니다. (%s의 구독 목록)'; -$lang['subscribe_error'] = '%s를 추가하는데 실패했습니다.(%s의 구독 목록)'; -$lang['subscribe_noaddress'] = '로그인 정보에 이메일 주소가 없습니다, 구독 목록에 추가할 수 없습니다.'; -$lang['unsubscribe_success'] = '%s를 제외시켰습니다. (%s의 구독 목록)'; -$lang['unsubscribe_error'] = '%s를 제외시키는데 실패했습니다.(%s의 구독 목록)'; +$lang['subscr_subscribe_noaddress'] = '등록된 주소가 없기 때문에 구독목록에 등록되지 않았습니다.'; +$lang['subscr_m_not_subscribed'] = '현재의 페이지나 네임스페이스에 구독등록이 되어있지 않습니다.'; +$lang['subscr_m_new_header'] = '구독 추가'; +$lang['subscr_m_current_header'] = '현재 구독중인 것들'; +$lang['subscr_m_unsubscribe'] = '구독 취소'; +$lang['subscr_m_subscribe'] = '구독'; +$lang['subscr_m_receive'] = '받기'; +$lang['subscr_style_every'] = '모든 변화를 이메일로 받기'; +$lang['subscr_style_digest'] = '각 페이지의 변화를 요약 (매 %.2f 일 마다)'; +$lang['subscr_style_list'] = '마지막 이메일 이후 변화된 페이지의 목록 (매 %.2f 일 마다)'; $lang['authmodfailed'] = '잘못된 사용자 인증 설정입니다. 관리자에게 문의하기 바랍니다.'; $lang['authtempfail'] = '사용자 인증이 일시적으로 불가능합니다. 만일 계속해서 문제가 발생하면 관리자에게 문의하기 바랍니다.'; $lang['i_chooselang'] = '사용하는 언어를 선택합니다.'; @@ -213,6 +252,7 @@ $lang['i_pol0'] = '개방형 위키 (누구나 읽기/쓰기/업 $lang['i_pol1'] = '공개형 위키 (누구나 읽을 수 있지만, 등록된 사용자만 쓰기/업로드가 가능합니다.)'; $lang['i_pol2'] = '폐쇄형 위키 (등록된 사용자만 읽기/쓰기/업로드가 가능합니다.)'; $lang['i_retry'] = '다시 시도'; +$lang['i_license'] = '내용의 배포를 위한 라이센스를 선택하세요.'; $lang['mu_intro'] = '여러 파일을 한번에 업로드할 수 있습니다. 파일 목록에 추가하려면 "찾기" 버튼을 클릭합니다. 파일 목록 추가 작업이 끝나면 "업로드" 버튼을 클릭하기 바랍니다. '; $lang['mu_gridname'] = '파일명'; $lang['mu_gridsize'] = '크기'; @@ -226,4 +266,14 @@ $lang['mu_fail'] = '업로드가 실패했습니다.'; $lang['mu_authfail'] = '세션 기간이 종료되었습니다.'; $lang['mu_progress'] = '@PCT@% 업로드되었습니다.'; $lang['mu_filetypes'] = '허용된 파일타입'; +$lang['mu_info'] = '업로드 되었습니다.'; +$lang['mu_lasterr'] = '마지막 에러:'; $lang['recent_global'] = '<b>%s</b> 네임스페이스를 구독중입니다. <a href="%s">전체위키 변경사항 </a>도 보실수 있습니다.'; +$lang['years'] = '%d 년 전'; +$lang['months'] = '%d 개월 전'; +$lang['weeks'] = '%d 주 전'; +$lang['days'] = '%d 일 전'; +$lang['hours'] = '%d 시간 전'; +$lang['minutes'] = '%d 분 전'; +$lang['seconds'] = '%d 초 전'; +$lang['wordblock'] = '스팸 문구를 포함하고 있어서 저장되지 않았습니다.'; diff --git a/inc/lang/ko/register.txt b/inc/lang/ko/register.txt index 999073a1d..24105efeb 100644 --- a/inc/lang/ko/register.txt +++ b/inc/lang/ko/register.txt @@ -1,4 +1,4 @@ ====== 새 사용자 등록 ====== -이 위키에 새 계정을 만들려면 아래의 모든 내용을 입력하십시오. **제대로 된 이메일 주소**를 사용하십시오. 그러나, 아래 내용을 입력했다고 해서 계정을 만들 수 있으리라고는 믿지 마십시오. 이곳은 내가 개인적으로 사용하는 곳이며, 계정을 만들어 주고 안주고는 내 마음입니다. 차라리, 내게 이메일을 보내서 신청하는 편이 더 나을 것입니다. 패스워드는 이 이메일로 보내집니다. 사용자명은 올바른 [[doku>pagename|pagename]] 이어야 합니다. +이 위키에 새 계정을 만들려면 아래의 모든 내용을 입력하세요. **제대로 된 이메일 주소**를 사용하세요. 암호를 입력하는 곳이 없다면 암호는 이 이메일로 보내집니다. 사용자명은 올바른 [[doku>pagename|pagename]] 이어야 합니다. diff --git a/inc/lang/ko/subscr_digest.txt b/inc/lang/ko/subscr_digest.txt new file mode 100644 index 000000000..2e9c87848 --- /dev/null +++ b/inc/lang/ko/subscr_digest.txt @@ -0,0 +1,18 @@ +안녕하세요! + +@TITLE@ 라는 제목의 페이지 @PAGE@ 가 변경되었습니다. + +변경사항은 다음과 같습니다: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +옛날 것: @OLDPAGE@ +새 것: @NEWPAGE@ + +이 페이지 변경알림의 설정을 바구려면, @DOKUWIKIURL@에 로그인한 뒤 +@SUBSCRIBE@ 를 방문하여 페이지나 이름공간의 구독을 취소하세요. + +-- +@DOKUWIKIURL@의 DokuWiki가 자동으로 만들어낸 메일입니다.
\ No newline at end of file diff --git a/inc/lang/ko/subscr_form.txt b/inc/lang/ko/subscr_form.txt new file mode 100644 index 000000000..31470f372 --- /dev/null +++ b/inc/lang/ko/subscr_form.txt @@ -0,0 +1,3 @@ +====== 구독 관리 ====== + +이 페이지는 현재의 페이지와 네임스페이스의 구독을 관리할 수있도록 해줍니다.
\ No newline at end of file diff --git a/inc/lang/ko/subscr_list.txt b/inc/lang/ko/subscr_list.txt new file mode 100644 index 000000000..2661a6a15 --- /dev/null +++ b/inc/lang/ko/subscr_list.txt @@ -0,0 +1,15 @@ +안녕하세요! + +@TITLE@ 라는 제목의 페이지 @PAGE@ 가 변경되었습니다. + +변경사항은 다음과 같습니다: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +이 페이지 변경알림의 설정을 바구려면, @DOKUWIKIURL@에 로그인한 뒤 +@SUBSCRIBE@ 를 방문하여 페이지나 이름공간의 구독을 취소하세요. + +-- +@DOKUWIKIURL@의 DokuWiki가 자동으로 만들어낸 메일입니다.
\ No newline at end of file diff --git a/inc/lang/ko/subscr_single.txt b/inc/lang/ko/subscr_single.txt new file mode 100644 index 000000000..1aa4d7efa --- /dev/null +++ b/inc/lang/ko/subscr_single.txt @@ -0,0 +1,21 @@ +안녕하세요! + +@TITLE@ 라는 제목의 페이지 @PAGE@ 가 변경되었습니다. + +변경사항은 다음과 같습니다: + +-------------------------------------------------------- +@DIFF@ +-------------------------------------------------------- + +날짜 : @DATE@ +사용자 : @USER@ +편집 요약 : @SUMMARY@ +구 버전 : @OLDPAGE@ +새 버전 : @NEWPAGE@ + +이 페이지 변경알림의 설정을 바구려면, @DOKUWIKIURL@에 로그인한 뒤 t +@NEWPAGE@ 를 방문하여 페이지나 이름공간의 구독을 취소하세요. + +-- +@DOKUWIKIURL@의 DokuWiki가 자동으로 만들어낸 메일입니다.
\ No newline at end of file diff --git a/inc/lang/zh/lang.php b/inc/lang/zh/lang.php index 9488cffe1..f819aff9a 100644 --- a/inc/lang/zh/lang.php +++ b/inc/lang/zh/lang.php @@ -10,6 +10,7 @@ * @author mr.jinyi@gmail.com * @author ben <ben@livetom.com> * @author lainme <lainme993@gmail.com> + * @author caii <zhoucaiqi@gmail.com> */ $lang['encoding'] = 'utf-8'; $lang['direction'] = 'ltr'; @@ -62,7 +63,7 @@ $lang['email'] = 'E-Mail'; $lang['register'] = '注册'; $lang['profile'] = '用户信息'; $lang['badlogin'] = '对不起,用户名或密码错误。'; -$lang['minoredit'] = '轻微修改'; +$lang['minoredit'] = '细微修改'; $lang['draftdate'] = '草稿自动保存于'; $lang['nosecedit'] = '在您编辑期间本页刚被他人修改过,局部信息已过期,故载入全页。'; $lang['regmissing'] = '对不起,您必须填写所有的区域。'; diff --git a/inc/load.php b/inc/load.php index 2f5be6d63..478ee7c76 100644 --- a/inc/load.php +++ b/inc/load.php @@ -74,6 +74,7 @@ function load_autoload($name){ 'DokuWikiFeedCreator' => DOKU_INC.'inc/feedcreator.class.php', 'Doku_Parser_Mode' => DOKU_INC.'inc/parser/parser.php', 'SafeFN' => DOKU_INC.'inc/SafeFN.class.php', + 'Sitemapper' => DOKU_INC.'inc/Sitemapper.php', 'DokuWiki_Action_Plugin' => DOKU_PLUGIN.'action.php', 'DokuWiki_Admin_Plugin' => DOKU_PLUGIN.'admin.php', diff --git a/inc/mail.php b/inc/mail.php index 38232d110..fb163585a 100644 --- a/inc/mail.php +++ b/inc/mail.php @@ -30,7 +30,39 @@ if(!defined('QUOTEDPRINTABLE_EOL')) define('QUOTEDPRINTABLE_EOL',"\015\012"); if (!defined('RFC2822_ATEXT')) define('RFC2822_ATEXT',"0-9a-zA-Z!#$%&'*+/=?^_`{|}~-"); if (!defined('PREG_PATTERN_VALID_EMAIL')) define('PREG_PATTERN_VALID_EMAIL', '['.RFC2822_ATEXT.']+(?:\.['.RFC2822_ATEXT.']+)*@(?i:[0-9a-z][0-9a-z-]*\.)+(?i:[a-z]{2,4}|museum|travel)'); +/** + * Prepare mailfrom replacement patterns + * + * @author Andreas Gohr <andi@splitbrain.org> + */ +function mail_setup(){ + global $conf; + global $INFO; + + $replace = array(); + + if(!empty($INFO['userinfo']['mail'])){ + $replace['@MAIL@'] = $INFO['userinfo']['mail']; + }else{ + $replace['@MAIL@'] = 'noreply@'.parse_url(DOKU_URL,PHP_URL_HOST); + } + if(!empty($_SERVER['REMOTE_USER'])){ + $replace['@USER@'] = $_SERVER['REMOTE_USER']; + }else{ + $replace['@USER@'] = 'noreply'; + } + + if(!empty($INFO['userinfo']['name'])){ + $replace['@NAME@'] = $INFO['userinfo']['name']; + }else{ + $replace['@NAME@'] = ''; + } + + $conf['mailfrom'] = str_replace(array_keys($replace), + array_values($replace), + $conf['mailfrom']); +} /** * UTF-8 autoencoding replacement for PHPs mail function diff --git a/inc/media.php b/inc/media.php index 3dacd12b7..69441352b 100644 --- a/inc/media.php +++ b/inc/media.php @@ -407,14 +407,9 @@ function media_notify($id,$file,$mime){ $text = str_replace('@MEDIA@',ml($id,'',true,'&',true),$text); $text = str_replace('@SIZE@',filesize_h(filesize($file)),$text); - $from = $conf['mailfrom']; - $from = str_replace('@USER@',$_SERVER['REMOTE_USER'],$from); - $from = str_replace('@NAME@',$INFO['userinfo']['name'],$from); - $from = str_replace('@MAIL@',$INFO['userinfo']['mail'],$from); - $subject = '['.$conf['title'].'] '.$lang['mail_upload'].' '.$id; - mail_send($conf['notify'],$subject,$text,$from); + mail_send($conf['notify'],$subject,$text,$conf['mailfrom']); } /** diff --git a/inc/parserutils.php b/inc/parserutils.php index 27a5190bd..a50e3f4f3 100644 --- a/inc/parserutils.php +++ b/inc/parserutils.php @@ -223,7 +223,7 @@ function p_get_instructions($text){ * @author Esther Brunner <esther@kaffeehaus.ch> */ function p_get_metadata($id, $key='', $render=false){ - global $ID, $INFO, $cache_metadata; + global $ID; // cache the current page // Benchmarking shows the current page's metadata is generally the only page metadata @@ -234,11 +234,7 @@ function p_get_metadata($id, $key='', $render=false){ // metadata has never been rendered before - do it! (but not for non-existent pages) if ($render && !isset($meta['current']['description']['abstract']) && page_exists($id)){ $meta = p_render_metadata($id, $meta); - io_saveFile(metaFN($id, '.meta'), serialize($meta)); - - // sync cached copies, including $INFO metadata - if (!empty($cache_metadata[$id])) $cache_metadata[$id] = $meta; - if (!empty($INFO) && ($id == $INFO['id'])) { $INFO['meta'] = $meta['current']; } + p_save_metadata($id, $meta); } $val = $meta['current']; @@ -256,6 +252,15 @@ function p_get_metadata($id, $key='', $render=false){ /** * sets metadata elements of a page * + * @see http://www.dokuwiki.org/devel:metadata#functions_to_get_and_set_metadata + * + * @param String $id is the ID of a wiki page + * @param Array $data is an array with key ⇒ value pairs to be set in the metadata + * @param Boolean $render whether or not the page metadata should be generated with the renderer + * @param Boolean $persistent indicates whether or not the particular metadata value will persist through + * the next metadata rendering. + * @return boolean true on success + * * @author Esther Brunner <esther@kaffeehaus.ch> */ function p_set_metadata($id, $data, $render=false, $persistent=true){ @@ -305,13 +310,7 @@ function p_set_metadata($id, $data, $render=false, $persistent=true){ // save only if metadata changed if ($meta == $orig) return true; - // sync cached copies, including $INFO metadata - global $cache_metadata, $INFO; - - if (!empty($cache_metadata[$id])) $cache_metadata[$id] = $meta; - if (!empty($INFO) && ($id == $INFO['id'])) { $INFO['meta'] = $meta['current']; } - - return io_saveFile(metaFN($id, '.meta'), serialize($meta)); + return p_save_metadata($id, $meta); } /** @@ -321,25 +320,22 @@ function p_set_metadata($id, $data, $render=false, $persistent=true){ * @author Michael Klier <chi@chimeric.de> */ function p_purge_metadata($id) { - $metafn = metaFN('id', '.meta'); - $meta = p_read_metadata($id); + $meta = p_read_metadata($id); foreach($meta['current'] as $key => $value) { if(is_array($meta[$key])) { $meta['current'][$key] = array(); } else { $meta['current'][$key] = ''; } + } - return io_saveFile(metaFN($id, '.meta'), serialize($meta)); + return p_save_metadata($id, $meta); } /** * read the metadata from source/cache for $id * (internal use only - called by p_get_metadata & p_set_metadata) * - * this function also converts the metadata from the original format to - * the current format ('current' & 'persistent' arrays) - * * @author Christopher Smith <chris@jalakai.co.uk> * * @param string $id absolute wiki page id @@ -356,26 +352,6 @@ function p_read_metadata($id,$cache=false) { $file = metaFN($id, '.meta'); $meta = @file_exists($file) ? unserialize(io_readFile($file, false)) : array('current'=>array(),'persistent'=>array()); - // convert $meta from old format to new (current+persistent) format - if (!isset($meta['current'])) { - $meta = array('current'=>$meta,'persistent'=>$meta); - - // remove non-persistent keys - unset($meta['persistent']['title']); - unset($meta['persistent']['description']['abstract']); - unset($meta['persistent']['description']['tableofcontents']); - unset($meta['persistent']['relation']['haspart']); - unset($meta['persistent']['relation']['references']); - unset($meta['persistent']['date']['valid']); - - if (empty($meta['persistent']['description'])) unset($meta['persistent']['description']); - if (empty($meta['persistent']['relation'])) unset($meta['persistent']['relation']); - if (empty($meta['persistent']['date'])) unset($meta['persistent']['date']); - - // save converted metadata - io_saveFile($file, serialize($meta)); - } - if ($cache) { $cache_metadata[(string)$id] = $meta; } @@ -384,6 +360,24 @@ function p_read_metadata($id,$cache=false) { } /** + * This is the backend function to save a metadata array to a file + * + * @param string $id absolute wiki page id + * @param array $meta metadata + * + * @return bool success / fail + */ +function p_save_metadata($id, $meta) { + // sync cached copies, including $INFO metadata + global $cache_metadata, $INFO; + + if (isset($cache_metadata[$id])) $cache_metadata[$id] = $meta; + if (!empty($INFO) && ($id == $INFO['id'])) { $INFO['meta'] = $meta['current']; } + + return io_saveFile(metaFN($id, '.meta'), serialize($meta)); +} + +/** * renders the metadata of a page * * @author Esther Brunner <esther@kaffeehaus.ch> diff --git a/inc/search.php b/inc/search.php index 8273eef8c..a6787c5d2 100644 --- a/inc/search.php +++ b/inc/search.php @@ -119,7 +119,7 @@ function search_index(&$data,$base,$file,$type,$lvl,$opts){ return false; } - $id = pathID($file); + $id = pathID($file,($type == 'd')); if($type=='d' && $conf['sneaky_index'] && auth_quickaclcheck($id.':') < AUTH_READ){ return false; @@ -511,8 +511,7 @@ function pathID($path,$keeptxt=false){ $id = utf8_decodeFN($path); $id = str_replace('/',':',$id); if(!$keeptxt) $id = preg_replace('#\.txt$#','',$id); - $id = preg_replace('#^:+#','',$id); - $id = preg_replace('#:+$#','',$id); + $id = trim($id, ':'); return $id; } @@ -550,7 +549,7 @@ function search_universal(&$data,$base,$file,$type,$lvl,$opts){ $return = true; // get ID and check if it is a valid one - $item['id'] = pathID($file,$opts['keeptxt']); + $item['id'] = pathID($file,($type == 'd' || $opts['keeptxt'])); if($item['id'] != cleanID($item['id'])){ if($opts['showmsg']) msg(hsc($item['id']).' is not a valid file name for DokuWiki - skipped',-1); diff --git a/inc/template.php b/inc/template.php index c2ce130ff..e2ea6e386 100644 --- a/inc/template.php +++ b/inc/template.php @@ -609,7 +609,7 @@ function tpl_get_action($type) { $type = 'subscribe'; $params['do'] = 'subscribe'; case 'subscribe': - if(!$conf['useacl'] || !$auth || $ACT !== 'show' || !$conf['subscribers'] || !$_SERVER['REMOTE_USER']){ + if(!$conf['useacl'] || !$auth || !$conf['subscribers'] || !$_SERVER['REMOTE_USER']){ return false; } break; @@ -617,7 +617,7 @@ function tpl_get_action($type) { break; case 'profile': if(!$conf['useacl'] || !$auth || !isset($_SERVER['REMOTE_USER']) || - !$auth->canDo('Profile') || ($ACT=='profile')){ + !$auth->canDo('Profile')){ return false; } break; @@ -796,7 +796,7 @@ function tpl_userinfo(){ global $lang; global $INFO; if(isset($_SERVER['REMOTE_USER'])){ - print $lang['loggedinas'].': '.$INFO['userinfo']['name'].' ('.$_SERVER['REMOTE_USER'].')'; + print $lang['loggedinas'].': '.hsc($INFO['userinfo']['name']).' ('.hsc($_SERVER['REMOTE_USER']).')'; return true; } return false; @@ -1359,5 +1359,18 @@ function tpl_flush(){ } +/** + * Use favicon.ico from data/media root directory if it exists, otherwise use + * the one in the template's image directory. + * + * @author Anika Henke <anika@selfthinker.org> + */ +function tpl_getFavicon() { + if (file_exists(mediaFN('favicon.ico'))) + return ml('favicon.ico'); + return DOKU_TPL.'images/favicon.ico'; +} + + //Setup VIM: ex: et ts=4 enc=utf-8 : |