Henrik Stoerner a écrit :
On Tue, Jun 27, 2006 at 12:05:14PM +0200, Charles Goyard wrote:
I made a small modification to bb-findhost.c so that when a search yields only one results, you get transported to that page.
I like the overall idea, but the implementation is not so nice.
Didn't I warned you :) ? Thank you for including this 'idea' into hobbit.
I made another modification, so that when all matches are on the same page, you get to that page at once. Why ? My Perl search engine on BB behaves this way, and most users use it not to jump to a specific host, but to a specific page: We use domain names to group hosts by project/farm/customer, like everything in the DMZ is called somehost.dmz01.tld. So to have a look at the dmz, people type "dmz01" (short, easy, ideal for lazy people). It proves so useful I can barely recall how the pages are organized :).
There's two flavours of the patch made against today's snapshot (Chances are you will find a better way to implement it :
- you get to the page without the host anchor ;
- you get to the first match.
Regards,
-- Charles