code: def soundex_en(word):
      # digits holds the soundex values for the alphabet
      r = ""
      if word:
          # Remember first character
          fc = None
          prevcode = None
          for char in word.lower():
              c = ord(char)
              if c >= 97 and c <= 122:  # a-z
                  if not fc:
                      fc = char
                  code = english_codes[c - 97]
                  # Don't append the code if it's the same as the previous
                  if code != prevcode:
                      r += code
                  prevcode = code
  
          # Replace first digit with first alpha character
          r = fc + r[1:]
  
      return r
  
imports: import re
  from whoosh.compat import iteritems
label_desc: Use image node_id 1 for calling a global function with example usage: soundex_en(word) and returns: r