From: <var...@us...> - 2015-02-27 17:05:49
|
Revision: 9571 http://sourceforge.net/p/phpwiki/code/9571 Author: vargenau Date: 2015-02-27 17:05:46 +0000 (Fri, 27 Feb 2015) Log Message: ----------- Remove acdropdown and livesearch Modified Paths: -------------- trunk/config/config-default.ini trunk/config/config-dist.ini trunk/configurator.php trunk/g trunk/lib/EditToolbar.php trunk/lib/IniConfig.php trunk/lib/WikiTheme.php trunk/lib/WysiwygEdit/spaw.php trunk/lib/plugin/LinkSearch.php trunk/lib/plugin/SemanticSearch.php trunk/lib/plugin/SemanticSearchAdvanced.php trunk/lib/plugin/WikiFormRich.php trunk/locale/de/LC_MESSAGES/phpwiki.mo trunk/locale/es/LC_MESSAGES/phpwiki.mo trunk/locale/fr/LC_MESSAGES/phpwiki.mo trunk/locale/it/LC_MESSAGES/phpwiki.mo trunk/locale/ja/LC_MESSAGES/phpwiki.mo trunk/locale/nl/LC_MESSAGES/phpwiki.mo trunk/locale/po/de.po trunk/locale/po/es.po trunk/locale/po/fr.po trunk/locale/po/it.po trunk/locale/po/ja.po trunk/locale/po/nl.po trunk/locale/po/phpwiki.pot trunk/locale/po/sv.po trunk/locale/po/zh.po trunk/locale/sv/LC_MESSAGES/phpwiki.mo trunk/locale/zh/LC_MESSAGES/phpwiki.mo trunk/pgsrc/ReleaseNotes trunk/themes/Crao/templates/navbar.tmpl trunk/themes/Sidebar/templates/search.tmpl trunk/themes/blog/themeinfo.php trunk/themes/default/templates/search.tmpl trunk/themes/default/toolbar.js Removed Paths: ------------- trunk/themes/default/moacdropdown/ trunk/themes/default/moacdropdown.js Modified: trunk/config/config-default.ini =================================================================== --- trunk/config/config-default.ini 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/config/config-default.ini 2015-02-27 17:05:46 UTC (rev 9571) @@ -22,10 +22,7 @@ ENABLE_CAPTCHA = false ENABLE_MAILNOTIFY = true USE_CAPTCHA_RANDOM_WORD = false -ENABLE_ACDROPDOWN = true DISABLE_UPLOAD_ONLY_ALLOWED_EXTENSIONS = false -; deprecated, because non-free -ENABLE_LIVESEARCH = false ENABLE_WYSIWYG = false WYSIWYG_BACKEND = Wikiwyg WYSIWYG_DEFAULT_PAGETYPE_HTML = false Modified: trunk/config/config-dist.ini =================================================================== --- trunk/config/config-dist.ini 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/config/config-dist.ini 2015-02-27 17:05:46 UTC (rev 9571) @@ -117,25 +117,10 @@ ; All internal action links do contain ref=nofollow ;GOOGLE_LINKS_NOFOLLOW = false -; LiveSearch enables immediate title search results via XMLHttpRequest. -; Displays the results in a dropdown under the titlesearch inputbox -; while typing. (experimental, only with certain themes) -; You'll have to copy livesearch.js from http://blog.bitflux.ch/wiki/LiveSearch -; to themes/default/ and define ENABLE_LIVESEARCH in config.ini to true. -; See themes/blog/themeinfo.php. -; We used the bitflux.ch library temporarily, but we changed to -; the better moacdropdown. -;ENABLE_LIVESEARCH = true - -; ENABLE_ACDROPDOWN replaces now ENABLE_LIVESEARCH -; http://momche.net/publish/article.php?page=acdropdown -;ENABLE_ACDROPDOWN = false - ; Aysnchronous ajax callbacks to dynamically display pages ; (as format=xml) on demand. ; Experimental feature for plugin DynamicIncludePage, which might fail on ; some strictly non-conformant entities. -; Note: TitleSearch ajax calls are enabled by ENABLE_ACDROPDOWN (xmlrpc, not xml) ;ENABLE_AJAX = false ; Experimental WikiPedia feature: Force Discussion/Article link at the topnavbar. Modified: trunk/configurator.php =================================================================== --- trunk/configurator.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/configurator.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -454,12 +454,6 @@ $properties["GOOGLE_LINKS_NOFOLLOW"] = new boolean_define_commented_optional('GOOGLE_LINKS_NOFOLLOW'); -$properties["ENABLE_LIVESEARCH"] = - new boolean_define_commented_optional('ENABLE_LIVESEARCH'); - -$properties["ENABLE_ACDROPDOWN"] = - new boolean_define_commented_optional('ENABLE_ACDROPDOWN'); - $properties["ENABLE_DISCUSSION_LINK"] = new boolean_define_commented_optional('ENABLE_DISCUSSION_LINK'); Modified: trunk/g =================================================================== --- trunk/g 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/g 2015-02-27 17:05:46 UTC (rev 9571) @@ -170,8 +170,6 @@ // Allow <div> and <span> in wiki code define('ENABLE_MARKUP_DIVSPAN', true); - // Disable ENABLE_ACDROPDOWN, it creates a <style> in the <body> (illegal) - define('ENABLE_ACDROPDOWN', false); define('ENABLE_AJAX', false); define('TOOLBAR_PAGELINK_PULLDOWN', false); Modified: trunk/lib/EditToolbar.php =================================================================== --- trunk/lib/EditToolbar.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/EditToolbar.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -27,7 +27,7 @@ * Features: * - save-preview and formatting buttons from mediawiki * - Search&Replace from walterzorn.de - * - pageinsert popup by Reini Urban (TODO: should be a pulldown, use acdropdown) + * - pageinsert popup by Reini Urban (TODO: should be a pulldown) */ class EditToolbar @@ -274,8 +274,7 @@ $sr_html = ''; } - //TODO: Delegate this to run-time with showing an hidden input at the right, and do - // a separate moacdropdown and xmlrpc:titleSearch. + //TODO: Delegate this to run-time with showing an hidden input at the right // Button to generate categories, display in extra window as popup and insert $sr_html = HTML($sr_html, $this->categoriesPulldown()); Modified: trunk/lib/IniConfig.php =================================================================== --- trunk/lib/IniConfig.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/IniConfig.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -187,7 +187,7 @@ // List of all valid config options to be define()d which take booleans. $_IC_VALID_BOOL = array ('ENABLE_PAGEPERM', 'ENABLE_EDIT_TOOLBAR', 'JS_SEARCHREPLACE', - 'ENABLE_XHTML_XML', 'ENABLE_DOUBLECLICKEDIT', 'ENABLE_LIVESEARCH', 'ENABLE_ACDROPDOWN', + 'ENABLE_XHTML_XML', 'ENABLE_DOUBLECLICKEDIT', 'USECACHE', 'WIKIDB_NOCACHE_MARKUP', 'ENABLE_REVERSE_DNS', 'ENCRYPTED_PASSWD', 'ZIPDUMP_AUTH', 'ENABLE_RAW_HTML', 'ENABLE_RAW_HTML_LOCKEDONLY', 'ENABLE_RAW_HTML_SAFE', Modified: trunk/lib/WikiTheme.php =================================================================== --- trunk/lib/WikiTheme.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/WikiTheme.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -268,18 +268,6 @@ or ENABLE_DOUBLECLICKEDIT ) $this->initDoubleClickEdit(); - - // will be replaced by acDropDown - if (ENABLE_LIVESEARCH) { // by bitflux.ch - $this->initLiveSearch(); - } - // replaces external LiveSearch - // enable ENABLE_AJAX for DynamicIncludePage - if (ENABLE_ACDROPDOWN or ENABLE_AJAX) { - $this->initMoAcDropDown(); - if (ENABLE_AJAX and DEBUG) // minified all together - $this->addMoreHeaders(JavaScript('', array('src' => $this->_findData("ajax.js")))); - } } function file($file) @@ -1616,41 +1604,6 @@ $this->addMoreAttr('body', 'DoubleClickEdit', HTML::raw(" ondblclick=\"url = document.URL; url2 = url; if (url.indexOf('?') != -1) url2 = url.slice(0, url.indexOf('?')); if ((url.indexOf('action') == -1) || (url.indexOf('action=browse') != -1)) document.location = url2 + '?action=edit';\"")); } - // Immediate title search results via XMLHTML(HttpRequest) - // by Bitflux GmbH, bitflux.ch. You need to install the livesearch.js separately. - // Google's or acdropdown is better. - private function initLiveSearch() - { - //subclasses of Sidebar will init this twice - static $already = 0; - if (!$this->HTML_DUMP_SUFFIX and !$already) { - $this->addMoreAttr('body', 'LiveSearch', - HTML::raw(" onload=\"liveSearchInit()")); - $this->addMoreHeaders(JavaScript('var liveSearchURI="' - . WikiURL(_("TitleSearch"), array(), true) . '";')); - $this->addMoreHeaders(JavaScript('', array - ('src' => $this->_findData('livesearch.js')))); - $already = 1; - } - } - - // Immediate title search results via XMLHttpRequest - // using the shipped moacdropdown js-lib - private function initMoAcDropDown() - { - //subclasses of Sidebar will init this twice - static $already = 0; - if (!$this->HTML_DUMP_SUFFIX and !$already) { - $dir = $this->_findData('moacdropdown'); - if (!DEBUG and ($css = $this->_findFile('moacdropdown/css/dropdown.css'))) { - $this->addMoreHeaders($this->_CSSlink(0, $css, 'all')); - } else { - $this->addMoreHeaders(HTML::style(array('type' => 'text/css'), " @import url( $dir/css/dropdown.css );\n")); - } - $already = 1; - } - } - function calendarLink($date = false) { return $this->calendarBase() . '/' . Modified: trunk/lib/WysiwygEdit/spaw.php =================================================================== --- trunk/lib/WysiwygEdit/spaw.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/WysiwygEdit/spaw.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -38,7 +38,6 @@ $width='100%', // width $height='300px', // height $css_stylesheet='', // css stylesheet file for content - $dropdown_data='' // data for dropdowns (style, font, etc.) */ $this->SPAW = new SPAW_Wysiwyg($id, $textarea->_content); $textarea->SetAttr('id', $name); Modified: trunk/lib/plugin/LinkSearch.php =================================================================== --- trunk/lib/plugin/LinkSearch.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/plugin/LinkSearch.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -63,7 +63,6 @@ 'value' => $args['page'], 'title' => _("Search only in these pages. With autocompletion."), 'class' => 'dropdown', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'false', 'autocomplete_list' => 'xmlrpc:wiki.titleSearch ^[S] 4' @@ -72,7 +71,6 @@ 'value' => $args['s'], 'title' => _("Filter by this link. These are pagenames. With autocompletion."), 'class' => 'dropdown', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'true', 'autocomplete_list' => 'xmlrpc:wiki.titleSearch ^[S] 4' Modified: trunk/lib/plugin/SemanticSearch.php =================================================================== --- trunk/lib/plugin/SemanticSearch.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/plugin/SemanticSearch.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -97,7 +97,6 @@ 'value' => $args['page'], 'title' => _("Search only in these pages. With autocompletion."), 'class' => 'dropdown', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'false', 'autocomplete_list' => 'xmlrpc:wiki.titleSearch ^[S] 4' @@ -110,7 +109,6 @@ 'title' => _("Filter by this relation. With autocompletion."), 'class' => 'dropdown', 'style' => 'width:10em', - 'acdropdown' => 'true', 'autocomplete_assoc' => 'false', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'true', @@ -120,7 +118,6 @@ 'value' => $args['s'], 'title' => _("Filter by this link. These are pagenames. With autocompletion."), 'class' => 'dropdown', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'true', 'autocomplete_list' => 'xmlrpc:wiki.titleSearch ^[S] 4' @@ -180,7 +177,6 @@ 'title' => _("Filter by this attribute name. With autocompletion."), 'class' => 'dropdown', 'style' => 'width:10em', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'true', 'autocomplete_assoc' => 'false', @@ -192,7 +188,6 @@ 'title' => _("Comparison operator. With autocompletion."), 'class' => 'dropdown', 'style' => 'width:2em', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'true', 'autocomplete_assoc' => 'false', @@ -202,7 +197,6 @@ 'value' => $args['s'], 'title' => _("Filter by this numeric attribute value. With autocompletion."), //? 'class' => 'dropdown', - 'acdropdown' => 'false', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'false', 'autocomplete_assoc' => 'false', Modified: trunk/lib/plugin/SemanticSearchAdvanced.php =================================================================== --- trunk/lib/plugin/SemanticSearchAdvanced.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/plugin/SemanticSearchAdvanced.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -89,7 +89,6 @@ 'value' => $args['page'], 'title' => _("Search only in these pages. With autocompletion."), 'class' => 'dropdown', - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_matchsubstring' => 'false', 'autocomplete_list' => 'xmlrpc:wiki.titleSearch ^[S] 4' @@ -100,7 +99,6 @@ $querybox = HTML::textarea(array('name' => 's', 'title' => _("Enter a valid query expression"), 'rows' => 4, - 'acdropdown' => 'true', 'autocomplete_complete' => 'true', 'autocomplete_assoc' => 'false', 'autocomplete_matchsubstring' => 'true', Modified: trunk/lib/plugin/WikiFormRich.php =================================================================== --- trunk/lib/plugin/WikiFormRich.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/lib/plugin/WikiFormRich.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -331,8 +331,6 @@ { global $request; $input['class'] = "dropdown"; - $input['acdropdown'] = "true"; - //$input['autocomplete'] = "OFF"; $input['autocomplete_complete'] = "true"; // only match begin: autocomplete_matchbegin, or $input['autocomplete_matchsubstring'] = "true"; @@ -348,7 +346,6 @@ static $tmpArray = 'tmpArray00'; // deferred remote xmlrpc call if (string_starts_with($input['method'], "dynxmlrpc:")) { - // how is server + method + args encoding parsed by acdropdown? $input['autocomplete_list'] = substr($input['method'], 3); if ($input['args']) $input['autocomplete_list'] .= (" " . $input['args']); Modified: trunk/locale/de/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/es/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/fr/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/it/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/ja/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/nl/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/po/de.po =================================================================== --- trunk/locale/po/de.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/de.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2000-10-31 02:23+0200\n" "Last-Translator: Reini Urban <ru...@x-...>, Carsten Klapp " "<car...@us...>, Helmer Pardun <pardunpress@t-online." @@ -5355,9 +5355,6 @@ msgid "Today" msgstr "Heute" -msgid "LiveSearch" -msgstr "LiveSuche" - #, php-format msgid "You are signed in as %s" msgstr "Sie sind angemeldet als %s" @@ -6125,6 +6122,9 @@ msgid "Y-m-d H:i" msgstr "" +#~ msgid "LiveSearch" +#~ msgstr "LiveSuche" + #~ msgid "Can't open ZIP file “%s” for reading" #~ msgstr "Konnte ZIP-Datei »%s« nicht zum Lesen öffnen" Modified: trunk/locale/po/es.po =================================================================== --- trunk/locale/po/es.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/es.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -11,7 +11,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2000-02-01 00:50-0500\n" "Last-Translator: Pablo Roca <pr...@cl...>\n" "Language-Team: \n" @@ -5230,9 +5230,6 @@ msgid "Today" msgstr "Hoy" -msgid "LiveSearch" -msgstr "" - #, php-format msgid "You are signed in as %s" msgstr "" Modified: trunk/locale/po/fr.po =================================================================== --- trunk/locale/po/fr.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/fr.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2004-06-22 21:10+0200\n" "Last-Translator: Pierrick Meignen <mei...@wa...>, Roland " "Trique <rol...@fr...>, Stéphane Gourichon <stephane.gourichon@lip6." @@ -5289,9 +5289,6 @@ msgid "Today" msgstr "Aujourd'hui" -msgid "LiveSearch" -msgstr "RechercheLive" - #, php-format msgid "You are signed in as %s" msgstr "Vous êtes connecté comme %s" @@ -6027,6 +6024,9 @@ msgid "Y-m-d H:i" msgstr "" +#~ msgid "LiveSearch" +#~ msgstr "RechercheLive" + #~ msgid "Can't open ZIP file “%s” for reading" #~ msgstr "Impossible d'ouvrir le fichier ZIP « %s » en lecture" Modified: trunk/locale/po/it.po =================================================================== --- trunk/locale/po/it.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/it.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2005-02-12 16:23+0100\n" "Last-Translator: Antonio Bonifati ant[(at)]monitor.deis.unical.it\n" "Language-Team: \n" @@ -5175,9 +5175,6 @@ msgid "Today" msgstr "Oggi" -msgid "LiveSearch" -msgstr "RicercaLive" - #, php-format msgid "You are signed in as %s" msgstr "Utente corrente: %s" @@ -5890,6 +5887,9 @@ msgid "Y-m-d H:i" msgstr "" +#~ msgid "LiveSearch" +#~ msgstr "RicercaLive" + #~ msgid "reverse" #~ msgstr "ritorni" Modified: trunk/locale/po/ja.po =================================================================== --- trunk/locale/po/ja.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/ja.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2003-06-07 09:01+0900\n" "Last-Translator: Tadashi Jokagi <web...@el...>\n" "Language-Team: LANGUAGE <LL...@li...>\n" @@ -5333,10 +5333,6 @@ msgid "Today" msgstr "今日" -#, fuzzy -msgid "LiveSearch" -msgstr "タイトル検索" - #, fuzzy, php-format msgid "You are signed in as %s" msgstr "%s としてサインインしました" @@ -6088,6 +6084,10 @@ msgstr "" #, fuzzy +#~ msgid "LiveSearch" +#~ msgstr "タイトル検索" + +#, fuzzy #~ msgid "sent to %s" #~ msgstr "%s に戻る" Modified: trunk/locale/po/nl.po =================================================================== --- trunk/locale/po/nl.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/nl.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2000-09-30 02:23+0200\n" "Last-Translator: Jan Nieuwenhuizen <ja...@gn...>\n" "Language-Team: Dutch <nl...@li...>\n" @@ -5167,9 +5167,6 @@ msgid "Today" msgstr "" -msgid "LiveSearch" -msgstr "LiveZoek" - #, php-format msgid "You are signed in as %s" msgstr "" @@ -5880,6 +5877,9 @@ msgid "Y-m-d H:i" msgstr "" +#~ msgid "LiveSearch" +#~ msgstr "LiveZoek" + #~ msgid "" #~ "Your home page has not been created yet so your preferences cannot not be " #~ "saved." Modified: trunk/locale/po/phpwiki.pot =================================================================== --- trunk/locale/po/phpwiki.pot 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/phpwiki.pot 2015-02-27 17:05:46 UTC (rev 9571) @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PhpWiki-1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2002-12-14 17:51-0500\n" "Last-Translator: Reini Urban <ru...@us...>\n" "Language-Team: LANGUAGE <LL...@li...>\n" @@ -5159,9 +5159,6 @@ msgid "Today" msgstr "" -msgid "LiveSearch" -msgstr "" - #, php-format msgid "You are signed in as %s" msgstr "" Modified: trunk/locale/po/sv.po =================================================================== --- trunk/locale/po/sv.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/sv.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2001-01-27 01:58+0200\n" "Last-Translator: Jon Åslund <jo...@he...>\n" "Language-Team: \n" @@ -5160,9 +5160,6 @@ msgid "Today" msgstr "" -msgid "LiveSearch" -msgstr "" - #, php-format msgid "You are signed in as %s" msgstr "" Modified: trunk/locale/po/zh.po =================================================================== --- trunk/locale/po/zh.po 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/locale/po/zh.po 2015-02-27 17:05:46 UTC (rev 9571) @@ -6,7 +6,7 @@ msgstr "" "Project-Id-Version: PhpWiki 1.5.2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-02-18 15:00+0100\n" +"POT-Creation-Date: 2015-02-27 17:55+0100\n" "PO-Revision-Date: 2004-04-21 10:08+0800\n" "Last-Translator: DruryL <dr...@us...>\n" "Language-Team: DruryL <dr...@us...>\n" @@ -5426,10 +5426,6 @@ msgid "Today" msgstr "今天" -#, fuzzy -msgid "LiveSearch" -msgstr "標題搜索" - #, fuzzy, php-format msgid "You are signed in as %s" msgstr "你必須簽入才能 %s." @@ -6193,6 +6189,10 @@ msgid "Y-m-d H:i" msgstr "" +#, fuzzy +#~ msgid "LiveSearch" +#~ msgstr "標題搜索" + #~ msgid "Can't open ZIP file “%s” for reading" #~ msgstr "無法開啟 ZIP 檔案 “%s” 進行讀取" Modified: trunk/locale/sv/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/locale/zh/LC_MESSAGES/phpwiki.mo =================================================================== (Binary files differ) Modified: trunk/pgsrc/ReleaseNotes =================================================================== --- trunk/pgsrc/ReleaseNotes 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/pgsrc/ReleaseNotes 2015-02-27 17:05:46 UTC (rev 9571) @@ -1,4 +1,4 @@ -Date: Fri, 20 Feb 2015 17:50:57 +0000 +Date: Fri, 27 Feb 2015 17:55:50 +0000 Mime-Version: 1.0 (Produced by PhpWiki 1.5.2) Content-Type: application/x-phpwiki; pagename=ReleaseNotes; @@ -23,6 +23,7 @@ * load theme pgsrc, if it exists * SUBPAGE_SEPARATOR removed, it must be '/' * RateIt plugin for Fusionforge +* remove acdropdown and livesearch == 1.5.2 2014-10-10 Marc-Etienne Vargenau == Modified: trunk/themes/Crao/templates/navbar.tmpl =================================================================== --- trunk/themes/Crao/templates/navbar.tmpl 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/themes/Crao/templates/navbar.tmpl 2015-02-27 17:05:46 UTC (rev 9571) @@ -40,15 +40,7 @@ onfocus="if (this.value == '<?php echo _("Search")?>') {this.value = '';}" onmouseout="window.status=''; return true;" onmouseover="window.status='<?php echo _("Search")?>'; return true;" -<?php if (ENABLE_LIVESEARCH) { ?> - title="<?php echo _("LiveSearch")?>" - onKeypress="liveSearchStart()" - onblur="setTimeout('closeResults()',2000); if (this.value == '') {this.value = '<?php echo _("Search")?>';}" /> - </div><br /><div class="align-left" id="LSResult"></div> -<?php } else { ?> title="<?php echo _("TitleSearch")?>" /> </div> -<?php } ?> </td></tr></table></div> </form> - Modified: trunk/themes/Sidebar/templates/search.tmpl =================================================================== --- trunk/themes/Sidebar/templates/search.tmpl 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/themes/Sidebar/templates/search.tmpl 2015-02-27 17:05:46 UTC (rev 9571) @@ -15,21 +15,8 @@ onmouseout="window.status=''; return true;" onmouseover="window.status='<?php echo _("Quick Search")?>'; return true;" accesskey="f" -<?php if (0 and ENABLE_ACDROPDOWN) { ?> - class="dropdown" id="searchInput" title="<?php echo _("LiveSearch") . " [$p-f]"?>" - style="width:115px;" - acdropdown="true" autocomplete_complete="false" autocomplete_matchsubstring="false" - autocomplete_list="xmlrpc:wiki.titleSearch [S] 4" /> -<?php } elseif (ENABLE_LIVESEARCH) { ?> - type="text" id="livesearch" title="<?php echo _("LiveSearch") . " [$p-f]"?>" - onKeypress="liveSearchStart()" - onblur="setTimeout('closeResults()',2000); if (this.value == '') {this.value = '<?php echo _("Search")?>';}" /> - <br/> - <div id="LSResult"> - </div> -<?php } else { ?> type="text" id="search" title="<?php echo _("Search term(s)") . " [$p-f]"?>" /> -<?php } ?> <?php echo $SEARCH_AFTER ?> +<?php echo $SEARCH_AFTER ?> </form> </div> Modified: trunk/themes/blog/themeinfo.php =================================================================== --- trunk/themes/blog/themeinfo.php 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/themes/blog/themeinfo.php 2015-02-27 17:05:46 UTC (rev 9571) @@ -29,15 +29,6 @@ * PageTrail: > .. > .. * Right sidebar boxes: Archives, Syndication, Links, GoogleAds * - * For the livesearch feature (autodropdown of the results while you tip) - * you'll have to copy livesearch.js from http://blog.bitflux.ch/wiki/LiveSearch - * to themes/default/, change the liveSearchReq.open line to: -liveSearchReq.open("GET", liveSearchURI + "?format=livesearch&paging=none&limit=25&s=" + document.forms.searchform.s.value); - * and define ENABLE_LIVESEARCH in config.ini to true. - * - * Better autodropdown's are in consideration: - * http://momche.net/publish/article.php?page=acdropdown) - * * Happy blogging. */ Deleted: trunk/themes/default/moacdropdown.js =================================================================== --- trunk/themes/default/moacdropdown.js 2015-02-27 16:12:26 UTC (rev 9570) +++ trunk/themes/default/moacdropdown.js 2015-02-27 17:05:46 UTC (rev 9571) @@ -1,1354 +0,0 @@ - -function cBrowser(){var userAgent=navigator.userAgent.toLowerCase() -this.version=parseInt(navigator.appVersion) -this.subVersion=parseFloat(navigator.appVersion) -this.ns=((userAgent.indexOf('mozilla')!=-1)&&((userAgent.indexOf('spoofer')==-1)&&(userAgent.indexOf('compatible')==-1))) -this.ns2=(this.ns&&(this.version==2)) -this.ns3=(this.ns&&(this.version==3)) -this.ns4b=(this.ns&&(this.subVersion<4.04)) -this.ns4=(this.ns&&(this.version==4)) -this.ns5=(this.ns&&(this.version==5)) -this.ie=(userAgent.indexOf('msie')!=-1) -this.ie3=(this.ie&&(this.version==2)) -this.ie4=(this.ie&&(this.version==4)&&(userAgent.indexOf('msie 4.')!=-1)) -this.ie5=(this.ie&&(this.version==4)&&(userAgent.indexOf('msie 5.0')!=-1)) -this.ie55=(this.ie&&(this.version==4)&&(userAgent.indexOf('msie 5.5')!=-1)) -this.ie6=(this.ie&&(this.version==4)&&(userAgent.indexOf('msie 6.0')!=-1)) -this.op3=(userAgent.indexOf('opera')!=-1) -this.win=(userAgent.indexOf('win')!=-1) -this.mac=(userAgent.indexOf('mac')!=-1) -this.unix=(userAgent.indexOf('x11')!=-1) -this.name=navigator.appName -this.dom=this.ns5||this.ie5||this.ie55||this.ie6} -var bw=new cBrowser() -cDomEvent={e:null,type:'',button:0,key:0,x:0,y:0,pagex:0,pagey:0,target:null,from:null,to:null} -cDomEvent.init=function(e) -{if(window.event)e=window.event -this.e=e -this.type=e.type -this.button=(e.which)?e.which:e.button -this.key=(e.which)?e.which:e.keyCode -this.target=(e.srcElement)?e.srcElement:e.originalTarget -this.currentTarget=(e.currentTarget)?e.currentTarget:e.srcElement -this.from=(e.originalTarget)?e.originalTarget:(e.fromElement)?e.fromElement:null -this.to=(e.currentTarget)?e.currentTarget:(e.toElement)?e.toElement:null -this.x=(e.layerX)?e.layerX:(e.offsetX)?e.offsetX:null -this.y=(e.layerY)?e.layerY:(e.offsetY)?e.offsetY:null -this.screenX=e.screenX -this.screenY=e.screenY -this.pageX=(e.pageX)?e.pageX:e.x+document.body.scrollLeft -this.pageY=(e.pageY)?e.pageY:e.y+document.body.scrollTop} -cDomEvent.getEvent=function(e) -{if(window.event)e=window.event -return{e:e,type:e.type,button:(e.which)?e.which:e.button,key:(e.which)?e.which:e.keyCode,target:(e.srcElement)?e.srcElement:e.originalTarget,currentTarget:(e.currentTarget)?e.currentTarget:e.srcElement,from:(e.originalTarget)?e.originalTarget:(e.fromElement)?e.fromElement:null,to:(e.currentTarget)?e.currentTarget:(e.toElement)?e.toElement:null,x:(e.layerX)?e.layerX:(e.offsetX)?e.offsetX:null,y:(e.layerY)?e.layerY:(e.offsetY)?e.offsetY:null,screenX:e.screenX,screenY:e.screenY,pageX:(e.pageX)?e.pageX:(e.clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)),pageY:(e.pageY)?e.pageY:(e.clientY+(document.documentElement.scrollTop||document.body.scrollTop))}} -cDomEvent.cancelEvent=function(e) -{if(e.preventDefault) -{e.preventDefault()} -e.returnValue=false -e.cancelBubble=true -return false} -cDomEvent.addEvent=function(hElement,sEvent,handler,bCapture) -{if(hElement.addEventListener) -{hElement.addEventListener(sEvent,handler,bCapture) -return true} -else if(hElement.attachEvent) -{return hElement.attachEvent('on'+sEvent,handler)} -else if(document.all||hElement.captureEvents) -{if(hElement.captureEvents)eval('hElement.captureEvents( Event.'+sEvent.toUpperCase()+' )') -eval('hElement.on'+sEvent+' = '+handler)} -else -{alert('Not implemented yet!')}} -cDomEvent.encapsulateEvent=function(hHandler) -{return function(hEvent) -{hEvent=cDomEvent.getEvent(hEvent) -hHandler.call(hEvent.target,hEvent.e)}} -cDomEvent.addEvent2=function(hElement,sEvent,handler,bCapture) -{if(hElement) -{if(hElement.addEventListener) -{hElement.addEventListener(sEvent,cDomEvent.encapsulateEvent(handler),bCapture) -return true} -else if(hElement.attachEvent) -{return hElement.attachEvent('on'+sEvent,cDomEvent.encapsulateEvent(handler))} -else -{alert('Not implemented yet!')}} -else -{}} -cDomEvent.addCustomEvent2=function(hElement,sEvent,handler) -{if(hElement) -{hElement[sEvent]=handler} -else -{}} -cDomEvent.removeEvent=function(hElement,sEvent,handler,bCapture) -{if(hElement.addEventListener) -{hElement.removeEventListener(sEvent,handler,bCapture) -return true} -else if(hElement.attachEvent) -{return hElement.detachEvent('on'+sEvent,handler)} -else if(document.all||hElement.captureEvents) -{eval('hElement.on'+sEvent+' = null')} -else -{alert('Not implemented yet!')}} -function MouseButton() -{if(document.layers) -{this.left=1 -this.middle=2 -this.right=3} -else if(document.all) -{this.left=1 -this.middle=4 -this.right=2} -else -{this.left=0 -this.middle=1 -this.right=2}} -var MB=new MouseButton() -if(document.ELEMENT_NODE==null) -{document.ELEMENT_NODE=1 -document.TEXT_NODE=3} -function getSubNodeByName(hNode,sNodeName) -{if(hNode!=null) -{var nNc=0 -var nC=0 -var hNodeChildren=hNode.childNodes -var hCNode=null -while(nC<hNodeChildren.length) -{hCNode=hNodeChildren.item(nC++) -if((hCNode.nodeType==1)&&(hCNode.nodeName.toLowerCase()==sNodeName)) -{return hCNode}}} -return null} -function getPrevNodeSibling(hNode) -{if(hNode!=null) -{do{hNode=hNode.previousSibling}while(hNode!=null&&hNode.nodeType!=1) -return hNode}} -function getNextNodeSibling(hNode) -{if(hNode!=null) -{do{hNode=hNode.nextSibling}while(hNode!=null&&hNode.nodeType!=1) -return hNode}} -function getLastSubNodeByName(hNode,sNodeName) -{if(hNode!=null) -{var nNc=0 -var nC=0 -var hNodeChildren=hNode.childNodes -var hCNode=null -var nLength=hNodeChildren.length-1 -while(nLength>=0) -{hCNode=hNodeChildren.item(nLength) -if((hCNode.nodeType==1)&&(hCNode.nodeName.toLowerCase()==sNodeName)) -{return hCNode} -nLength--}} -return null} -function getSubNodeByProperty(hNode,sProperty,sPropValue) -{if(hNode!=null) -{var nNc=0 -var nC=0 -var hNodeChildren=hNode.childNodes -var hCNode=null -var sAttribute -var hProp -sPropValue=sPropValue.toLowerCase() -while(nC<hNodeChildren.length) -{hCNode=hNodeChildren.item(nC++) -if(hCNode.nodeType==document.ELEMENT_NODE) -{hProp=eval('hCNode.'+sProperty) -if(typeof(sPropValue)!='undefined') -{if(hProp.toLowerCase()==sPropValue) -{return hCNode}} -else -{return hCNode}} -nNc++}} -return null} -function findAttribute(hNode,sAtt) -{sAtt=sAtt.toLowerCase() -for(var nI=0;nI<hNode.attributes.length;nI++) -{if(hNode.attributes.item(nI).nodeName.toLowerCase()==sAtt) -{return hNode.attributes.item(nI).nodeValue}} -return null} -function getSubNodeByAttribute(hNode,sAtt,sAttValue) -{if(hNode!=null) -{var nNc=0 -var nC=0 -var hNodeChildren=hNode.childNodes -var hCNode=null -var sAttribute -sAttValue=sAttValue.toLowerCase() -while(nC<hNodeChildren.length) -{hCNode=hNodeChildren.item(nC++) -if(hCNode.nodeType==document.ELEMENT_NODE) -{sAttribute=hCNode.getAttribute(sAtt) -if(sAttribute&&sAttribute.toLowerCase()==sAttValue) -return hCNode} -nNc++}} -return null} -function getLastSubNodeByAttribute(hNode,sAtt,sAttValue) -{if(hNode!=null) -{var nNc=0 -var nC=0 -var hNodeChildren=hNode.childNodes -var hCNode=null -var nLength=hNodeChildren.length-1 -while(nLength>=0) -{hCNode=hNodeChildren.item(nLength) -if(hCNode.nodeType==document.ELEMENT_NODE) -{sAttribute=hCNode.getAttribute(sAtt) -if(sAttribute&&sAttribute.toLowerCase()==sAttValue) -return hCNode} -nLength--}} -return null} -function getParentByTagName(hNode,sParentTagName) -{while((hNode.tagName)&&!(/(body|html)/i.test(hNode.tagName))) -{if(hNode.tagName==sParentTagName) -{return hNode} -hNode=hNode.parentNode} -return null} -function getParentByAttribute(hNode,sAtt,sAttValue) -{while((hNode.tagName)&&!(/(body|html)/i.test(hNode.tagName))) -{var sAttr=hNode.getAttribute(sAtt) -if(sAttr!=null&&sAttr.toString().length>0) -{if(sAttValue!==null) -{if(sAttr==sAttValue) -{return hNode}} -else -{return hNode}} -hNode=hNode.parentNode} -return null} -function getParentByProperty(hNode,sProperty,sPropValue) -{while((hNode.tagName)&&!(/(body|html)/i.test(hNode.tagName))) -{var hProp=eval('hNode.'+sProperty) -if(hProp!=null&&hProp.toString().length>0) -{if(sPropValue!==null) -{if(hProp==sPropValue) -{return hNode}} -else -{return hNode}} -hNode=hNode.parentNode} -return null} -function getNodeText(hNode) -{if(hNode==null) -{return''} -var sRes -if(hNode.hasChildNodes()) -{sRes=hNode.childNodes.item(0).nodeValue} -else -{sRes=hNode.text} -return sRes} -function cDomExtension(hParent,aSelectors,hInitFunction) -{this.hParent=hParent -this.aSelectors=aSelectors -this.hInitFunction=hInitFunction} -cDomExtensionManager={aExtensions:new Array()} -cDomExtensionManager.register=function(hDomExtension) -{cDomExtensionManager.aExtensions.push(hDomExtension)} -cDomExtensionManager.initSelector=function(hParent,sSelector,hInitFunction) -{var hSelectorRegEx -var hAttributeRegEx -var aSelectorData -var aAttributeData -var sAttribute -hSelectorRegEx=/([a-z0-9_]*)\[?([^\]]*)\]?/i -hAttributeRegEx=/([a-z0-9_]*)([\*\^\$]?)(=?)(([a-z0-9_=]*))/i -if(hSelectorRegEx.test(sSelector)&&!/[@#\.]/.test(sSelector)) -{aSelectorData=hSelectorRegEx.exec(sSelector) -if(aSelectorData[1]!='') -{hGroup=hParent.getElementsByTagName(aSelectorData[1].toLowerCase()) -for(nI=0;nI<hGroup.length;nI++) -{hGroup[nI].markExt=true} -for(nI=0;nI<hGroup.length;nI++) -{if(!hGroup[nI].markExt) -{continue} -else -{hGroup[nI].markExt=false} -if(aSelectorData[2]=='') -{if(hGroup[nI].tagName.toLowerCase()==aSelectorData[1].toLowerCase()) -{hInitFunction(hGroup[nI])}} -else -{aAttributeData=hAttributeRegEx.exec(aSelectorData[2]) -if(aAttributeData[1]=='class') -{sAttribute=hGroup[nI].className} -else -{sAttribute=hGroup[nI].getAttribute(aAttributeData[1])} -if(sAttribute!=null&&sAttribute.length>0) -{if(aAttributeData[3]=='=') -{if(aAttributeData[2]=='') -{if(sAttribute==aAttributeData[4]) -{hInitFunction(hGroup[nI])}} -else -{switch(aAttributeData[2]) -{case'^':if(sAttribute.indexOf(aAttributeData[4])==0) -{hInitFunction(hGroup[nI])} -break -case'$':if(sAttribute.lastIndexOf(aAttributeData[4])==sAttribute.length-aAttributeData[4].length) -{hInitFunction(hGroup[nI])} -break -case'*':if(sAttribute.indexOf(aAttributeData[4])>=0) -{hInitFunction(hGroup[nI])} -break}}} -else -{hInitFunction(hGroup[nI])}}}} -return}} -hSelectorRegEx=/([a-z0-9_]*)([\.#@]?)([a-z0-9_=~]*)/i -hAttributeRegEx=/([a-z0-9_]*)([=~])?([a-z0-9_]*)/i -aSelectorData=hSelectorRegEx.exec(sSelector) -if(aSelectorData[1]!='') -{var hGroup=hParent.getElementsByTagName(aSelectorData[1]) -for(nI=0;nI<hGroup.length;nI++) -{hGroup[nI].markExt=true} -for(nI=0;nI<hGroup.length;nI++) -{if(!hGroup[nI].markExt) -{continue} -else -{hGroup[nI].markExt=false} -if(aSelectorData[2]!='') -{switch(aSelectorData[2]) -{case'.':if(hGroup[nI].className==aSelectorData[3]) -{hInitFunction(hGroup[nI])} -break -case'#':if(hGroup[nI].id==aSelectorData[3]) -{hInitFunction(hGroup[nI])} -break -case'@':aAttributeData=hAttributeRegEx.exec(aSelectorData[3]) -sAttribute=hGroup[nI].getAttribute(aAttributeData[1]) -if(sAttribute!=null&&sAttribute.length>0) -{if(aAttributeData[3]!='') -{if(aAttributeData[2]=='=') -{if(sAttribute==aAttributeData[3]) -{hInitFunction(hGroup[nI])}} -else -{if(sAttribute.indexOf(aAttributeData[3])>=0) -{hInitFunction(hGroup[nI])}}} -else -{hInitFunction(hGroup[nI])}} -break}}}}} -cDomExtensionManager.initialize=function() -{var hDomExtension=null -var aSelectors -for(var nKey in cDomExtensionManager.aExtensions) -{aSelectors=cDomExtensionManager.aExtensions[nKey].aSelectors -for(var nKey2 in aSelectors) -{cDomExtensionManager.initSelector(cDomExtensionManager.aExtensions[nKey].hParent,aSelectors[nKey2],cDomExtensionManager.aExtensions[nKey].hInitFunction)}}} -if(window.addEventListener) -{window.addEventListener('load',cDomExtensionManager.initialize,false)} -else if(window.attachEvent) -{window.attachEvent('onload',cDomExtensionManager.initialize)} -function cDomObject(sId) -{if(bw.dom||bw.ie) -{this.hElement=document.getElementById(sId) -this.hStyle=this.hElement.style}} -cDomObject.prototype.getWidth=function() -{return cDomObject.getWidth(this.hElement)} -cDomObject.getWidth=function(hElement) -{if(hElement.currentStyle) -{var nWidth=parseInt(hElement.currentStyle.width) -if(isNaN(nWidth)) -{return parseInt(hElement.offsetWidth)} -else -{return nWidth}} -else -{return parseInt(hElement.offsetWidth)}} -cDomObject.prototype.getHeight=function() -{return cDomObject.getHeight(this.hElement)} -cDomObject.getHeight=function(hElement) -{if(hElement.currentStyle) -{var nHeight=parseInt(hElement.currentStyle.height) -if(isNaN(nHeight)) -{return parseInt(hElement.offsetHeight)} -else -{return nHeight}} -else -{return parseInt(hElement.offsetHeight)}} -cDomObject.prototype.getLeft=function() -{return cDomObject.getLeft(this.hElement)} -cDomObject.getLeft=function(hElement) -{return parseInt(hElement.offsetLeft)} -cDomObject.prototype.getTop=function() -{return cDomObject.getTop(this.hElement)} -cDomObject.getTop=function(hElement) -{return parseInt(hElement.offsetTop)} -cDomObject.getOffsetParam=function(hElement,sParam,hLimitParent) -{var nRes=0 -if(hLimitParent==null) -{hLimitParent=document.body.parentElement} -while(hElement!=hLimitParent) -{nRes+=eval('hElement.'+sParam) -if(!hElement.offsetParent){break} -hElement=hElement.offsetParent} -return nRes} -cDomObject.getScrollOffset=function(hElement,sParam,hLimitParent) -{nRes=0 -if(hLimitParent==null) -{hLimitParent=document.body.parentElement} -while(hElement!=hLimitParent) -{nRes+=eval('hElement.scroll'+sParam) -if(!hElement.offsetParent){break} -hElement=hElement.parentNode} -return nRes} -function getDomDocumentPrefix(){if(getDomDocumentPrefix.prefix) -return getDomDocumentPrefix.prefix;var prefixes=["MSXML2","Microsoft","MSXML","MSXML3"];var o;for(var i=0;i<prefixes.length;i++){try{o=new ActiveXObject(prefixes[i]+".DomDocument");return getDomDocumentPrefix.prefix=prefixes[i];} -catch(ex){};} -throw new Error("Could not find an installed XML parser");} -function getXmlHttpPrefix(){if(getXmlHttpPrefix.prefix) -return getXmlHttpPrefix.prefix;var prefixes=["MSXML2","Microsoft","MSXML","MSXML3"];var o;for(var i=0;i<prefixes.length;i++){try{o=new ActiveXObject(prefixes[i]+".XmlHttp");return getXmlHttpPrefix.prefix=prefixes[i];} -catch(ex){};} -throw new Error("Could not find an installed XML parser");} -function XmlHttp(){} -XmlHttp.create=function(){try{if(window.XMLHttpRequest){var req=new XMLHttpRequest();if(req.readyState==null){req.readyState=1;req.addEventListener("load",function(){req.readyState=4;if(typeof req.onreadystatechange=="function") -req.onreadystatechange();},false);} -return req;} -if(window.ActiveXObject){return new ActiveXObject(getXmlHttpPrefix()+".XmlHttp");}} -catch(ex){} -throw new Error("Your browser does not support XmlHttp objects");};function XmlDocument(){} -XmlDocument.create=function(){try{if(document.implementation&&document.implementation.createDocument){var doc=document.implementation.createDocument("","",null);if(doc.readyState==null){doc.readyState=1;doc.addEventListener("load",function(){doc.readyState=4;if(typeof doc.onreadystatechange=="function") -doc.onreadystatechange();},false);} -return doc;} -if(window.ActiveXObject) -return new ActiveXObject(getDomDocumentPrefix()+".DomDocument");} -catch(ex){} -throw new Error("Your browser does not support XmlDocument objects");};if(window.DOMParser&&window.XMLSerializer&&window.Node&&Node.prototype&&Node.prototype.__defineGetter__){Document.prototype.loadXML=function(s){var doc2=(new DOMParser()).parseFromString(s,"text/xml");while(this.hasChildNodes()) -this.removeChild(this.lastChild);for(var i=0;i<doc2.childNodes.length;i++){this.appendChild(this.importNode(doc2.childNodes[i],true));}};Document.prototype.__defineGetter__("xml",function(){return(new XMLSerializer()).serializeToString(this);});} -function cAutocomplete(sInputId) -{this.init(sInputId)} -var xmlrpc_url;cAutocomplete.CS_NAME='Autocomplete component' -cAutocomplete.CS_OBJ_NAME='AC_COMPONENT' -cAutocomplete.CS_LIST_PREFIX='ACL_' -cAutocomplete.CS_BUTTON_PREFIX='ACB_' -cAutocomplete.CS_INPUT_PREFIX='AC_' -cAutocomplete.CS_HIDDEN_INPUT_PREFIX='ACH_' -cAutocomplete.CS_INPUT_CLASSNAME='dropdown' -cAutocomplete.CB_AUTOINIT=true -cAutocomplete.CB_AUTOCOMPLETE=false -cAutocomplete.CB_FORCECORRECT=false -cAutocomplete.CB_MATCHSUBSTRING=false -cAutocomplete.CS_SEPARATOR=',' -cAutocomplete.CS_ARRAY_SEPARATOR=',' -cAutocomplete.CB_MATCHSTRINGBEGIN=true -cAutocomplete.CN_OFFSET_TOP=2 -cAutocomplete.CN_OFFSET_LEFT=-1 -cAutocomplete.CN_LINE_HEIGHT=19 -cAutocomplete.CN_NUMBER_OF_LINES=10 -cAutocomplete.CN_HEIGHT_FIX=2 -cAutocomplete.CN_CLEAR_TIMEOUT=300 -cAutocomplete.CN_SHOW_TIMEOUT=400 -cAutocomplete.CN_REMOTE_SHOW_TIMEOUT=1000 -cAutocomplete.CN_MARK_TIMEOUT=400 -cAutocomplete.hListDisplayed=null -cAutocomplete.nCount=0 -cAutocomplete.autoInit=function() -{var nI=0 -var hACE=null -var sLangAtt -var nInputsLength=document.getElementsByTagName('INPUT').length -for(nI=0;nI<nInputsLength;nI++) -{if(document.getElementsByTagName('INPUT')[nI].type.toLowerCase()=='text') -{sLangAtt=document.getElementsByTagName('INPUT')[nI].getAttribute('acdropdown') -if(sLangAtt!=null&&sLangAtt.length>0) -{if(document.getElementsByTagName('INPUT')[nI].id==null||document.getElementsByTagName('INPUT')[nI].id.length==0) -{document.getElementsByTagName('INPUT')[nI].id=cAutocomplete.CS_OBJ_NAME+cAutocomplete.nCount} -hACE=new cAutocomplete(document.getElementsByTagName('INPUT')[nI].id)}}} -var nTALength=document.getElementsByTagName('TEXTAREA').length -for(nI=0;nI<nTALength;nI++) -{sLangAtt=document.getElementsByTagName('TEXTAREA')[nI].getAttribute('acdropdown') -if(sLangAtt!=null&&sLangAtt.length>0) -{if(document.getElementsByTagName('TEXTAREA')[nI].id==null||document.getElementsByTagName('TEXTAREA')[nI].id.length==0) -{document.getElementsByTagName('TEXTAREA')[nI].id=cAutocomplete.CS_OBJ_NAME+cAutocomplete.nCount} -hACE=new cAutocomplete(document.getElementsByTagName('TEXTAREA')[nI].id)}} -var nSelectsLength=document.getElementsByTagName('SELECT').length -var aSelect=null -for(nI=0;nI<nSelectsLength;nI++) -{aSelect=document.getElementsByTagName('SELECT')[nI] -sLangAtt=aSelect.getAttribute('acdropdown') -if(sLangAtt!=null&&sLangAtt.length>0) -{if(aSelect.id==null||aSelect.id.length==0) -{aSelect.id=cAutocomplete.CS_OBJ_NAME+cAutocomplete.nCount} -hACE=new cAutocomplete(aSelect.id) -nSelectsLength-- -nI--}}} -if(cAutocomplete.CB_AUTOINIT) -{if(window.attachEvent) -{window.attachEvent('onload',cAutocomplete.autoInit)} -else if(window.addEventListener) -{window.addEventListener('load',cAutocomplete.autoInit,false)}} -cAutocomplete.prototype.init=function(sInputId) -{this.bDebug=false -this.sInputId=sInputId -this.sListId=cAutocomplete.CS_LIST_PREFIX+sInputId -this.sObjName=cAutocomplete.CS_OBJ_NAME+'_obj_'+(cAutocomplete.nCount++) -this.hObj=this.sObjName -this.hActiveSelection=null -this.nSelectedItemIdx=-1 -this.sLastActiveValue='' -this.sActiveValue='' -this.bListDisplayed=false -this.nItemsDisplayed=0 -this.bAssociative=true -this.sHiddenInputId=null -this.bHasButton=false -this.aData=null -this.aSearchData=new Array() -this.bSorted=false -this.nLastMatchLength=0 -this.bForceCorrect=cAutocomplete.CB_FORCECORRECT -var sForceCorrect=document.getElementById(this.sInputId).getAttribute('autocomplete_forcecorrect') -if(sForceCorrect!=null&&sForceCorrect.length>0) -{this.bForceCorrect=eval(sForceCorrect)} -this.bMatchBegin=cAutocomplete.CB_MATCHSTRINGBEGIN -var sMatchBegin=document.getElementById(this.sInputId).getAttribute('autocomplete_matchbegin') -if(sMatchBegin!=null&&sMatchBegin.length>0) -{this.bMatchBegin=eval(sMatchBegin)} -this.bMatchSubstring=cAutocomplete.CB_MATCHSUBSTRING -var sMatchSubstring=document.getElementById(this.sInputId).getAttribute('autocomplete_matchsubstring') -if(sMatchSubstring!=null&&sMatchSubstring.length>0) -{this.bMatchSubstring=eval(sMatchSubstring)} -this.bAutoComplete=cAutocomplete.CB_AUTOCOMPLETE -this.bAutocompleted=false -var sAutoComplete=document.getElementById(this.sInputId).getAttribute('autocomplete_complete') -if(sAutoComplete!=null&&sAutoComplete.length>0) -{this.bAutoComplete=eval(sAutoComplete)} -this.formatOptions=null -var sFormatFunction=document.getElementById(this.sInputId).getAttribute('autocomplete_format') -if(sFormatFunction!=null&&sFormatFunction.length>0) -{this.formatOptions=eval(sFormatFunction)} -this.onSelect=null -var sOnSelectFunction=document.getElementById(this.sInputId).getAttribute('autocomplete_onselect') -if(sOnSelectFunction!=null&&sOnSelectFunction.length>0) -{this.onSelect=eval(sOnSelectFunction)} -if(this.getListArrayType()=='url'||this.getListArrayType()=='xmlrpc') -{this.bAssociative=false -this.bRemoteList=true -this.sListURL=this.getListURL() -this.hXMLHttp=XmlHttp.create() -this.bXMLRPC=(this.getListArrayType()=='xmlrpc')} -else -{this.bRemoteList=false} -var sAssociative=document.getElementById(this.sInputId).getAttribute('autocomplete_assoc') -if(sAssociative!=null&&sAssociative.length>0) -{this.bAssociative=eval(sAssociative)} -this.initListArray() -this.initListContainer() -this.initInput() -eval(this.hObj+'= this')} -cAutocomplete.prototype.initInput=function() -{var hInput=document.getElementById(this.sInputId) -hInput.hAutocomplete=this -var hContainer=document.getElementById(this.sListId) -hContainer.hAutocomplete=this -var nWidth=hInput.offsetWidth -if(!nWidth||nWidth==0) -{var hOWInput=hInput.cloneNode(true) -hOWInput.style.position='absolute' -hOWInput.style.top='-1000px' -document.body.appendChild(hOWInput) -var nWidth=hOWInput.offsetWidth -document.body.removeChild(hOWInput)} -var sInputName=hInput.name -var hForm=hInput.form -var bHasButton=false -var sHiddenValue=hInput.value -var sValue=hInput.type.toLowerCase()=='text'?hInput.value:'' -var sHasButton=hInput.getAttribute('autocomplete_button') -if(sHasButton!=null&&sHasButton.length>0) -{bHasButton=true} -if(hInput.type.toLowerCase()=='select-one') -{bHasButton=true -if(hInput.selectedIndex>=0) -{sHiddenValue=hInput.options[hInput.selectedIndex].value -sValue=hInput.options[hInput.selectedIndex].text}} -if(hForm) -{var hHiddenInput=document.createElement('INPUT') -hHiddenInput.id=cAutocomplete.CS_HIDDEN_INPUT_PREFIX+this.sInputId -hHiddenInput.type='hidden' -hForm.appendChild(hHiddenInput) -if(this.bAssociative) -{hHiddenInput.name=sInputName -hInput.name=cAutocomplete.CS_INPUT_PREFIX+sInputName} -else -{hHiddenInput.name=cAutocomplete.CS_INPUT_PREFIX+sInputName} -hHiddenInput.value=sHiddenValue -this.sHiddenInputId=hHiddenInput.id} -if(bHasButton) -{this.bHasButton=true -var hInputContainer=document.createElement('DIV') -hInputContainer.className='acinputContainer' -hInputContainer.style.width=nWidth -var hInputButton=document.createElement('INPUT') -hInputButton.id=cAutocomplete.CS_BUTTON_PREFIX+this.sInputId -hInputButton.type='button' -hInputButton.className='button' -hInputButton.tabIndex=hInput.tabIndex+1 -hInputButton.hAutocomplete=this -var hNewInput=document.createElement('INPUT') -if(this.bAssociative) -{hNewInput.name=cAutocomplete.CS_INPUT_PREFIX+sInputName} -else -{hNewInput.name=sInputName} -hNewInput.type='text' -hNewInput.value=sValue -hNewInput.style.width=nWidth-22 -hNewInput.className=cAutocomplete.CS_INPUT_CLASSNAME -hNewInput.tabIndex=hInput.tabIndex -hNewInput.hAutocomplete=this -hInputContainer.appendChild(hNewInput) -hInputContainer.appendChild(hInputButton) -hInput.parentNode.replaceChild(hInputContainer,hInput) -hNewInput.id=this.sInputId -hInput=hNewInput} -if(hInput.attachEvent) -{hInput.attachEvent('onkeyup',cAutocomplete.onInputKeyUp) -hInput.attachEvent('onkeyup',cAutocomplete.saveCaretPosition) -hInput.attachEvent('onkeydown',cAutocomplete.onInputKeyDown) -hInput.attachEvent('onblur',cAutocomplete.onInputBlur) -hInput.attachEvent('onfocus',cAutocomplete.onInputFocus) -if(hInputButton) -{hInputButton.attachEvent('onclick',cAutocomplete.onButtonClick)}} -else if(hInput.addEventListener) -{hInput.addEventListener('keyup',cAutocomplete.onInputKeyUp,false) -hInput.addEventListener('keyup',cAutocomplete.saveCaretPosition,false) -hInput.addEventListener('keydown',cAutocomplete.onInputKeyDown,false) -hInput.addEventListener('keypress',cAutocomplete.onInputKeyPress,false) -hInput.addEventListener('blur',cAutocomplete.onInputBlur,false) -hInput.addEventListener('focus',cAutocomplete.onInputFocus,false) -if(hInputButton) -{hInputButton.addEventListener('click',cAutocomplete.onButtonClick,false)}} -hInput.setAttribute('autocomplete','OFF') -if(hForm) -{if(hForm.attachEvent) -{hForm.attachEvent('onsubmit',cAutocomplete.onFormSubmit) -if(this.bDebug){this.debug("attachEvent added")}} -else if(hForm.addEventListener) -{hForm.addEventListener('submit',cAutocomplete.onFormSubmit,false) -if(this.bDebug){this.debug("addEventListener")}}}} -cAutocomplete.prototype.initListContainer=function() -{var hInput=document.getElementById(this.sInputId) -var hContainer=document.createElement('DIV') -hContainer.className='autocomplete_holder' -hContainer.id=this.sListId -hContainer.style.zIndex=10000+cAutocomplete.nCount -hContainer.hAutocomplete=this -var hFirstBorder=document.createElement('DIV') -hFirstBorder.className='autocomplete_firstborder' -var hSecondBorder=document.createElement('DIV') -hSecondBorder.className='autocomplete_secondborder' -var hList=document.createElement('UL') -hList.className='autocomplete' -hSecondBorder.appendChild(hList) -hFirstBorder.appendChild(hSecondBorder) -hContainer.appendChild(hFirstBorder) -document.body.appendChild(hContainer) -if(hContainer.attachEvent) -{hContainer.attachEvent('onblur',cAutocomplete.onListBlur) -hContainer.attachEvent('onfocus',cAutocomplete.onListFocus)} -else if(hInput.addEventListener) -{hContainer.addEventListener('blur',cAutocomplete.onListBlur,false) -hContainer.addEventListener('focus',cAutocomplete.onListFocus,false)} -if(hContainer.attachEvent) -{hContainer.attachEvent('onclick',cAutocomplete.onItemClick)} -else if(hContainer.addEventListener) -{hContainer.addEventListener('click',cAutocomplete.onItemClick,false)}} -cAutocomplete.prototype.createList=function() -{var hInput=document.getElementById(this.sInputId) -var hContainer=document.getElementById(this.sListId) -var hList=hContainer.getElementsByTagName('UL')[0] -if(hList) -{hList=hList.parentNode.removeChild(hList) -while(hList.hasChildNodes()) -{hList.removeChild(hList.childNodes[0])}} -var hListItem=null -var hListItemLink=null -var hArrKey=null -var sArrEl=null -var hArr=this.aData -var nI=0 -var sRealText -for(hArrKey in hArr) -{sArrEl=hArr[hArrKey] -hListItem=document.createElement('LI') -hListItemLink=document.createElement('A') -hListItemLink.setAttribute('itemvalue',hArrKey) -var sArrData=sArrEl.split(cAutocomplete.CS_ARRAY_SEPARATOR) -if(sArrData.length>1) -{this.aData[hArrKey]=sArrData[0] -hListItemLink.setAttribute('itemdata',sArrEl.substring(sArrEl.indexOf(cAutocomplete.CS_ARRAY_SEPARATOR)+1)) -sRealText=sArrData[0]} -else -{sRealText=sArrEl} -hListItemLink.href='#' -hListItemLink.appendChild(document.createTextNode(sRealText)) -hListItemLink.realText=sRealText -if(nI==this.nSelectedItemIdx) -{this.hActiveSelection=hListItemLink -this.hActiveSelection.className='selected'} -hListItem.appendChild(hListItemLink) -hList.appendChild(hListItem) -this.aSearchData[nI++]=sRealText.toLowerCase()} -var hSecondBorder=hContainer.firstChild.firstChild -hSecondBorder.appendChild(hList) -this.bListUpdated=false} -cAutocomplete.prototype.initListArray=function() -{var hInput=document.getElementById(this.sInputId) -var hArr=null -if(hInput.type.toLowerCase()=='select-one') -{hArr=new Object() -for(var nI=0;nI<hInput.options.length;nI++) -{hArrKey=hInput.options.item(nI).value -sArrEl=hInput.options.item(nI).text -hArr[hArrKey]=sArrEl -if(hInput.options.item(nI).selected) -{this.nSelectedItemIdx=nI}}} -else -{var sAA=hInput.getAttribute('autocomplete_list') -var sAAS=hInput.getAttribute('autocomplete_list_sort') -var sArrayType=this.getListArrayType() -switch(sArrayType) -{case'array':hArr=eval(sAA.substring(6)) -break -case'list':hArr=new Array() -var hTmpArray=sAA.substring(5).split('|') -var aValueArr -for(hKey in hTmpArray) -{aValueArr=hTmpArray[hKey].split(cAutocomplete.CS_ARRAY_SEPARATOR) -if(aValueArr.length==1) -{hArr[hKey]=hTmpArray[hKey] -this.bAssociative=false} -else -{hArr[aValueArr[0]]=aValueArr[1]}} -break} -if(sAAS!=null&&eval(sAAS)) -{this.bSorted=true -this.aData=hArr.sort() -hArr=hArr.sort()}} -this.setArray(hArr)} -cAutocomplete.prototype.setArray=function(sArray) -{if(typeof sArray=='string') -{this.aData=eval(sArray)} -else -{this.aData=sArray} -this.bListUpdated=true} -cAutocomplete.prototype.setListArray=function(sArray) -{this.setArray(sArray) -this.updateAndShowList()} -cAutocomplete.prototype.getListArrayType=function() -{var hInput=document.getElementById(this.sInputId) -var sAA=hInput.getAttribute('autocomplete_list') -if(sAA!=null&&sAA.length>0) -{if(sAA.indexOf('array:')>=0) -{return'array'} -else if(sAA.indexOf('list:')>=0) -{return'list'} -else if(sAA.indexOf('url:')>=0) -{return'url'} -else if(sAA.indexOf('xmlrpc:')>=0) -{return'xmlrpc'}}} -cAutocomplete.prototype.getListURL=function() -{var hInput=document.getElementById(this.sInputId) -var sAA=hInput.getAttribute('autocomplete_list') -if(sAA!=null&&sAA.length>0) -{if(sAA.indexOf('url:')>=0) -{return sAA.substring(4)} -if(sAA.indexOf('xmlrpc:')>=0) -{return sAA.substring(7)}}} -cAutocomplete.prototype.setListURL=function(sURL) -{this.sListURL=sURL;} -cAutocomplete.prototype.onXmlHttpLoad=function() -{if(this.hXMLHttp.readyState==4) -{var hError=this.hXMLHttp.parseError -if(hError&&hError.errorCode!=0) -{alert(hError.reason)} -else -{this.afterRemoteLoad()}}} -cAutocomplete.prototype.onXMLRPCHttpLoad=function() -{if(this.hXMLHttp.readyState==4) -{var hError=this.hXMLHttp.parseError -if(hError&&hError.errorCode!=0) -{alert(hError.reason)} -else -{this.afterRemoteLoadXMLRPC()}}} -cAutocomplete.prototype.loadXMLRPCListArray=function() -{var sURL=this.sListURL -var xmlrpc_url=data_path+'/RPC2.php' -var aMethodArgs=sURL.split(' ') -var sMethodName=aMethodArgs[0] -var sStartWith=this.getStringForAutocompletion(this.sActiveValue,this.nInsertPoint) -sStartWith=sStartWith.replace(/^\s/,'') -sStartWith=sStartWith.replace(/\s$/,'') -if(sMethodName.indexOf('?')>0) -{sMethodName=sMethodName.replace('/^.+\?/','') -sURL=sURL.replace('/\?.+$/','')} -else -{sURL=xmlrpc_url} -if(sMethodName.length<1) -{var hInput=document.getElementById(this.sInputId) -hInput.value=this.sActiveValue -return} -var sRequest='<?xml version=\'1.0\' encoding="utf-8" ?>\n' -sRequest+='<methodCall><methodName>'+sMethodName+'</methodName>\n' -if(aMethodArgs.length<=1) -{sRequest+='<params/>\n'} -else -{sRequest+='<params>\n' -for(var nI=1;nI<aMethodArgs.length;nI++) -{var sArg=aMethodArgs[nI];if(sArg.indexOf('[S]')>=0) -{sArg=sArg.replace('[S]',sStartWith)} -sRequest+='<param><value><string>' -sRequest+=sArg -sRequest+='</string></value></param>\n'} -sRequest+='</params>\n'} -sRequest+='</methodCall>' -if(this.bDebug){this.debug('url: "'+sURL+'" sRequest: "'+sRequest.substring(20)+'"')} -this.hXMLHttp.open('POST',sURL,true) -var hAC=this -this.hXMLHttp.onreadystatechange=function(){hAC.onXMLRPCHttpLoad()} -this.hXMLHttp.send(sRequest)} -cAutocomplete.prototype.loadListArray=function() -{var sURL=this.sListURL -var sStartWith=this.getStringForAutocompletion(this.sActiveValue,this.nInsertPoint) -sStartWith=sStartWith.replace(/^\s/,'') -sStartWith=sStartWith.replace(/\s$/,'') -if(sURL.indexOf('[S]')>=0) -{sURL=sURL.replace('[S]',sStartWith)} -else -{sURL+=this.sActiveValue} -this.hXMLHttp.open('GET',sURL,true) -var hAC=this -this.hXMLHttp.onreadystatechange=function(){hAC.onXmlHttpLoad()} -this.hXMLHttp.send(null)} -cAutocomplete.prototype.afterRemoteLoad=function() -{var hInput=document.getElementById(this.sInputId) -var hArr=new Array() -var hTmpArray=this.hXMLHttp.responseText.split('|') -var aValueArr -for(hKey in hTmpArray) -{aValueArr=hTmpArray[hKey].split(cAutocomplete.CS_ARRAY_SEPARATOR) -if(aValueArr.length==1) -{hArr[hKey]=hTmpArray[hKey]} -else -{hArr[aValueArr[0]]=hTmpArray[hKey].substr(hTmpArray[hKey].indexOf(cAutocomplete.CS_ARRAY_SEPARATOR)+1)}} -hInput.className='' -hInput.readonly=false -hInput.value=this.sActiveValue -this.setListArray(hArr)} -cAutocomplete.prototype.afterRemoteLoadXMLRPC=function() -{var hInput=document.getElementById(this.sInputId) -var hArr=new Array() -sResult=this.hXMLHttp.responseText -if(this.bDebug){this.debug("respons... [truncated message content] |