Notices
Reply

Thread: How to correct/fix search query typos using .htaccess

 
Tools Search
  #1  
Old October 11th, 2011, 12:05 PM
Fighting the good fight...
Join Date: June 24th, 2005
Location: Brighton, CO USA
Posts: 2,284
Send a message via AIM to Convergence
Hello brainiacs!

Get a lot of users who mistype phrases in their search queries. Am trying to use .htaccess to rewrite the mistyped word within the query so the search results have the correctly spelled word and not the typo.

IE:

User types in doubl edged sword or knife with doubl edge

Want to be able to replace doubl with double automatically using .htaccess -

Any clues?

Thanks!
__________________
If I were doing any better, they'd have to clone me!
  #2  
Old October 11th, 2011, 01:44 PM
ABW Ambassador
Join Date: October 14th, 2007
Location: MA
Posts: 1,886
I would set up canonical meta tags to tell robots which one is the correct query instead of putting in .htaccess.

What if the query has missing letters, but also mistakes? "doble eged swords"
If you set up in .htaccess for all possible corrections, your .htaccess will be looooong.

Official Google Webmaster Central Blog: Specify your canonical
  #3  
Old October 11th, 2011, 01:56 PM
Fighting the good fight...
Join Date: June 24th, 2005
Location: Brighton, CO USA
Posts: 2,284
Send a message via AIM to Convergence
Quote:
Originally Posted by ladidah View Post
I would set up canonical meta tags to tell robots which one is the correct query instead of putting in .htaccess.

What if the query has missing letters, but also mistakes? "doble eged swords"
If you set up in .htaccess for all possible corrections, your .htaccess will be looooong.

Official Google Webmaster Central Blog: Specify your canonical
Thanks, ladidah -

Don't think that helps. The search query displays in a search results page with anywhere from two to two thousand (paginated) results.

Want to catch the most popular typo search queries - about 40 words before the incorrect results are displayed...
__________________
If I were doing any better, they'd have to clone me!
Join ABW to remove this sponsored message.
  #4  
Old October 12th, 2011, 12:24 PM
Director of IT
Join Date: October 4th, 2011
Location: Chicago, Illinois
Posts: 6
I can not think of any good way of doing this without seriously jeopardizing site speed. You would have to set up a rewrite condition and rule for every possible combination.

If you must use .htaccess you may want to look up how to implement a RewriteMap.

This would be best handled on the server side. Here you have lots of flexibility and options but will require programming and probable database work.
  #5  
Old October 12th, 2011, 12:32 PM
Fighting the good fight...
Join Date: June 24th, 2005
Location: Brighton, CO USA
Posts: 2,284
Send a message via AIM to Convergence
Thanks, Jason!

Will take a gander and try it out...
__________________
If I were doing any better, they'd have to clone me!
Reply

Tools Search
Search:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Typos and Misspellings for AdWords John Powell PPC Search Engines 8 May 4th, 2007 04:09 PM
Too many typos and spelling mistakes Catwoman Midnight Cafe' 8 May 31st, 2004 04:26 PM
Dear Linkshare, please fix the Search Engine!?! HumbleFish Rakuten LinkShare 9 April 23rd, 2004 07:10 AM
too many typos here Midnight Cafe' 16 July 28th, 2002 05:34 PM


Content Relevant URLs by vBSEO ©2011, Crawlability, Inc.