I have built a search engine in PHP using the LIKE operator, now I want to build a search engine in PHP using a relevancy algorithm. I just want it to rank results by keyword occurrences. I want it to search the entire table a specify every time a search is preformed. I don't want to index the information and then search it. Could someone please show me some code for a relevency algorithm that ranks by keyword occurrence and explian in detail how it works.