processor_transliteration.inc 445 B

1234567891011121314151617181920
  1. <?php
  2. /**
  3. * @file
  4. * Contains SearchApiTransliteration.
  5. */
  6. /**
  7. * Processor for making searches insensitive to accents and other non-ASCII characters.
  8. */
  9. class SearchApiTransliteration extends SearchApiAbstractProcessor {
  10. protected function process(&$value) {
  11. // We don't touch integers, NULL values or the like.
  12. if (is_string($value)) {
  13. $value = transliteration_get($value, '', language_default('language'));
  14. }
  15. }
  16. }