[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Webglimpse Home]

Re: Seach syntax



At 04:31 AM 12/17/99 -0800, Harry Putnam wrote:
>
>I've established a webglimpse archive of a unix tutorial.  Using
>wgall.html in that directory I'm attempting a search for this string:
>
>[name]   I mean the literal interpretation not a character set.

Hmm - the \[name\] shoule have worked, but if not, try this:

Edit the webglimpse cgi-bin script to add a -k switch to the glimpse
command line.  In version 1.7.7 its at line 482:

$cmd = "$GLIMPSE_LOC -U -W -j -y $OPT_nonascii $OPT_file $OPT_linenums $
OPT_age $OPT_case $OPT_whole $OPT_errors -H $indexdir " .

change to

$cmd = "$GLIMPSE_LOC -U -W -j -k -y $OPT_nonascii $OPT_file $OPT_linenums $
OPT_age $OPT_case $OPT_whole $OPT_errors -H $indexdir " .
===============================================================
>From the glimpse docs:

-k No symbol in the pattern is treated as a meta character. For example,
glimpse -k 'a(b|c)*d' will find the occurrences
of a(b|c)*d whereas glimpse 'a(b|c)*d' will find substrings that match the
regular expression 'a(b|c)*d'. (The only
exception is ^ at the beginning of the pattern and $ at the end of the
pattern, which are still interpreted in the usual way.
Use \^ or \$ if you need them verbatim.) 

Hope that helps...

--G

>I've tried plain "[name]" (no quotes) seems to find almost everything
>so assume it searches for any of those characters.
>
>The page that displays the hits shows this query as:
>Results for query "[name]".  
>
>Ok fine try escpaing the brackets "\[name\]" (no quotes)
>
>Using the jump to line feature, things like this are what is hylited:
>\n   newline
>\ddd octal value ddd
>END     { printf "\n%10s %6d %5d\n", "TOTAL", area, pop }
>
>
>Double escapes finds nothing  "\\[name\\]"
>
>
>What is the proper syntax to find literal   "[name]" (no quotes)?
>
>
------------------------------------------------------------
Golda Velez         gvelez@tucson.com	        520-620-6878
Internet Workshop                          http://tucson.com
Webglimpse Search Software             http://webglimpse.net
		~~~~~~~~~~~~~~~~~~~~~~~~~~~
 Help organize the world - index your own corner of the web