App/Search
XOWA can search for a page by title
Contents
Search by page title
XOWA can find a page by words in its title. For example, typing earth
will pull up all titles with the word, including Earth and History of Earth. More complicated searches can be performed, such as earth + (history, future) -middle
XOWA currently cannot search by text within a page (full-text search). This will be added in a future version.
Usage
There are three ways to use search:
- Type into the address bar. A list of suggestions appear underneath.
- Type into the suggest box. A list of suggestions appear underneath. Note that this box is near the top-right hand corner of the page between "View HTML" and the magnifying glass icon.
-
Type "?:some word" into the address bar. For example, enter
?:earth
in the address bar when in Simple Wikipedia
Syntax
The following syntax is supported for search text:
name | description | symbol | example | finds | skips |
---|---|---|---|---|---|
single word |
finds pages which start with this word (automatic wildcard at the end) |
earth
|
Earth |
||
single word with space |
finds pages which have this word exactly (no automatic wildcard) |
earth
|
Earth |
Earthquake | |
multiple words | finds pages which have all these words |
earth history
|
History of Earth |
Earth | |
wildcard | finds pages which start with these letters |
*
|
earth*
|
Earth |
|
finds pages which end with these letters |
*
|
*earth
|
Earth |
||
finds pages which start / end with these letters |
*
|
e*h
|
Earth |
||
not | skips pages which have this word |
-
|
earth -history
|
Earth | History of Earth |
or | includes pages which have this word |
,
|
earth, history
|
History of Earth |
|
and | requires pages to have this word |
+
|
earth + history
|
History of Earth |
History Earth |
quote | requires pages to have this exact text |
"
|
"earth history"
|
Earth history |
History of Earth |
parentheses | allows complicated and / or grouping |
( )
|
earth + (history, future)
|
History of Earth |
Earth |
escape | allows searching for any symbols above |
\
|
c\+\+
|
C++ |
General
-
Spaces are ignored
-
earth, history
is the same asearth , history
orearth ,history
-
-
Incorrect terms are auto-corrected as per the following:
-
earth - history
is the same asearth history
-
earth +
is the same asearth
-
earth,
is the same asearth
-
"earth
is the same as"earth"
. Note that"earth history
becomes"earth" history
. -
(earth
is the same asearth
-
c\
is the same asc
-
Wildcard
-
Wildcards are automatically added to the last word. For example,
earth histor
is the same asearth histor*
. -
Wildcards will be slower than non-wildcarded versions. In terms of performance, they are ranked as following:
-
end of word
-
faster, especially when word is longer. EX:
abcdefghi*
vsa*
-
may be slow for certain multi-word queries. EX:
page meg*
-
uses the
>=
<
operators:word_text >= ? AND word_text < ?
- uses an INDEX scan
-
faster, especially when word is longer. EX:
-
beginning of word / middle of word
-
may be fast if matching a common string. EX:
*a
,*arth
-
will be slow for queries that don't match results. EX:
ea*rh
-
uses the LIKE operator:
word_text LIKE ? ESCAPE '|'
- uses a TABLE scan
-
may be fast if matching a common string. EX:
-
end of word
Not
-
-
only works at the start of the word-
earth hi-story
is the same asearth "hi-story"
. In other words, the-
is literal
-
-
-
must be used with a word. Entering just-QXZ
will return 0 results
Quote
-
Quotes can also be used for escaping. For example
"c++"
is the same asc\+\+
-
Quotes must be doubled up inside quotes. For example
"a""b"
means search for a word witha"b
Sorting
By default, XOWA returns results sorted by "page length descending". In other words, the largest page would be the first in the list and the smallest page would be the last.
If a wiki is built with PageRank, or if a wiki is downloaded from archive.org, then the results will be sorted by "PageRank descending". See Options/Search for enabling PageRank.
Background database search
By default, XOWA runs database searches in the background. This will return results to the screen quickly for complicated searches. For example, consider a search for Earth*
:
- When the search runs in the background, the first result shows up in 2 seconds, and more results show up every second afterwards. The search will complete in 5 seconds.
- When the search does not run in the background, all the results show up at the 5 second mark.
While a search is running in the background, there will be a link called Stop searching
. Clicking on the link will stop the background search, though the current results may be incomplete.
Finally, all search results are cached. The first time you search for Earth*
, XOWA will search the database. Every time afterwards, it will pull the results up from memory. If you restart XOWA, it will search the database again.
Database update
XOWA wikis created before v3.3.4.1 will need to be upgraded. XOWA will detect if an upgrade is needed, and show a message box for confirmation. The upgrade process will take a few minutes.
Note that new wikis created after v3.3.4.1 will automatically be in the new format.
Options
There are 2 pages for configuring Search
- Configure PageRank: See Options/Search
- Configure Address bar autocomplete: See Options/Search_suggest