'Returns True if string s occurs in the given element (case-insensitive).'

def _contains(self, e, s):

    s = re.sub('^contains\\((.*?)\\)$', '\\1', s)
    s = re.sub('^[\\"\']|[\\"\']$', '', s)
    s = _decode_space(s)
    return (re.search(s.lower(), e.content.lower()) is not None)
