Hi, here`s part2 of the restricted namespace search thingy > > Ideally the following search queries should work: > > > > 'foo @bar @baz' - searches for foo in the namespaces bar and baz Works now, no namespace limit, you can use as much "@ns" as you like. But there`s no specialchar-handling yet, I think this isn`t needed here thus I guess noone expects correct results when stuff like \^'` or else is entered (the regex will just fail). What do you think? > > 'foo bar @baz' - searches for foo and bar in namespace baz > > works > > > '"foo bar" @baz' - searches for the phrase "foo bar" in namespace baz > > works - but I recognized that, for some particular reason I am not aware > of, only the last word is highlighted. The patch is attached to this mail (really ;-)). Cheers Michael -- Michael Klier mail: chi@xxxxxxxxxxx www: http://www.chimeric.de icq: 206179334 key: http://www.chimeric.de/chi.asc key-id: 0x8308F551
New patches: [namespace-restricted fulltext-search part2 'Michael Klier <chi@xxxxxxxxxxx>'**20060518204647 - now its possible to restrict the fulltext-search to multible namespaces Examples: searchword @ns1 @ns2 @ns3 "exact phrase" @ns1 @ns2 @ns3 ] { hunk ./inc/fulltext.php 54 + $pattern = implode('|^',$q['ns']); hunk ./inc/fulltext.php 56 - if(!preg_match('/^'.$q['ns'].'/',$key)) { + if(!preg_match('/^'.$pattern.'/',$key)) { hunk ./inc/fulltext.php 267 - $q['ns'] = ''; + $q['ns'] = array(); hunk ./inc/fulltext.php 273 - if(preg_match('/([^@]*)@([^@]*)/',$query,$match)) { + if(preg_match('/([^@]*)@(.*)/',$query,$match)) { hunk ./inc/fulltext.php 275 - $q['ns'] = $match[2]; + $q['ns'] = explode('@',preg_replace("/ /",'',$match[2])); } Context: [namespace restricted fulltext-search 'Michael Klier <chi@xxxxxxxxxxx>'**20060518161855 - The fulltext-search can now be restricted to a given namespace seperated by an "@" ] [gzip content-encoding option Ben Coburn <btcoburn@xxxxxxxxxxxxx>**20060516084132 - Enables gzip compression of output xhtml for browsers that support it. For example the wiki:syntax page takes up 46.80KB raw, but only 9.88KB gzip encoded. - Setting is configurable through the config plugin. ] [javascript fix to mak sumarry checking use addEvent Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060512073949] [avoid trolling in io_lock() Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060517165023] [lt lang update Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060517105635] [jpg quality option Ben Coburn <btcoburn@xxxxxxxxxxxxx>**20060516062321 - Adds a jpg quality setting for scaled images (Some images were getting too many jpg artifacts at the hard-coded compression setting.) - Creates a group for the media settings in the config plugin. ] [fr update Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060515190136] [nl update Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060515185820] [add config plugin support for plugin defined setting classes chris@xxxxxxxxxxxxx**20060511083209] [more info is gathered on metaupdate in background indexer Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060511191450 The background indexer now gathers info on contributors and modification dates from the changelog when adding the missing meta info. A new io_grep function was added which might be useful for other parts in the Wiki as well. ] [config plugin ui organization Ben Coburn <btcoburn@xxxxxxxxxxxxx>**20060510065732 - organizes the configuration settings list into chunks - provides a table of contents for the configuration chunks - provides one chunk for each plugin with configurable settings - provides one chunk for the active template (if it has settings) - provides the config file setting as a tool-tip on the setting label ex. $conf['start'] - provides for localization of useful strings - generates a "smart" fallback name for plugins and templates - plugin and template sections are only shown if they have settings - current configuration list is organized into chunks Note: There are NEW strings to translate into the non-english language files. ] [TAG develsnap 2006-05-07 Andreas Gohr <andi@xxxxxxxxxxxxxx>**20060507173508] Patch bundle hash: c55bd3c4008007230010504885d1343757e23d96