- Timestamp:
- 2003-06-09T09:45:54+12:00 (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/colservr/mgqueryfilter.cpp
r4193 r4507 495 495 } 496 496 } 497 498 #ifdef GSDL_BBC_COLLECTION 499 // This is a special hack for the BBC collection's ProgNumber and zzabn 500 // indexes (they're built this way to prevent mg_perf_hash_build from 501 // dying at build time) 502 503 // if we're searching the zzAB/zzAN or ProgNumber index we want to 504 // remove all non-alphanumeric characters from the query string 505 text_t longindex; text_tarray splitindex; 506 indexmap.to2from ((*query_here).index, longindex); 507 splitchar (longindex.begin(), longindex.end(), ':', splitindex); 508 text_t &indextype = splitindex[1]; 509 if (indextype == "zzabn" || indextype == "ProgNumber") { 510 text_t new_querystring; 511 text_t::const_iterator here = (*query_here).querystring.begin(); 512 text_t::const_iterator end = (*query_here).querystring.end(); 513 while (here != end) { 514 if ((*here >= 'a' && *here <= 'z') || (*here >= 'A' && *here <= 'Z') || 515 (*here >= '0' && *here <= '9')) { 516 new_querystring.push_back (*here); 517 } 518 here ++; 519 } 520 (*query_here).querystring = new_querystring; 521 } 522 #endif 497 523 query_here ++; 498 524 }
Note:
See TracChangeset
for help on using the changeset viewer.