PDA

View Full Version : Reverse indexing


bloodjelly
01-28-2004, 04:09 PM
Hi -

I'm wondering how difficult it would be to reverse the usage of the common_words.txt file so that only words in that file would be indexed, and all other words would be excluded. Any ideas? :D

bloodjelly
01-31-2004, 04:21 PM
No ideas? I know this is kind of a tough/weird request, but I'm very interested in trying it.

Charter
02-05-2004, 04:46 PM
Hi. Perhaps search the files for the $common_words variable and then negate and/or remove the code related to $common_words wherever it appears.

bloodjelly
02-07-2004, 02:31 PM
Thanks!:D I thought maybe that would work but it seemed too simple for such a complex program. Anyway I'll give it a try.

hgw
08-20-2004, 08:59 AM
Hi bloodjelly,
did you succeed with exluding words so that only certain words are digged? Thanks, Guenter

bloodjelly
08-22-2004, 11:39 AM
Hi Guenter -

Yes, reversing the indexing worked great. You simply reverse all the lines in search_functions and robot_functions (and maybe spider.php) that refer to $common_words.

So, if a line says "if $word != $common_words" you would change it to "if $word == $common_words".

WebDiva 2.0
08-25-2004, 09:06 PM
So, in effect, by placing what you "want" to index in common_words you can eliminate any sites having words outside of that like porn, etc. I thought to create a dirty word filter to prevent searches for smut things. I do not like these searches or even to see them in the stats file. It's awfully disgusting what some very sick people will search for.

I'm working to write a short file that will take the days top-X searches and can display them on the index page as a hyperlink query. When is finsihed, will post it here in this forums.