def get_meaning(soup):
    """
    解析获取单词解释
    不同解释间用|分割

    :soup:  网页的Beautiful对象
    :return:包含全部中文解释的字符串
            若没有找到则返回None
    """

    result = str()
    # 获取单词中文解释并放在结果集中
    zhn_meanings = soup.find(attrs={'id': 'en-simple-means'})
    if zhn_meanings is not None:
        zhn_meanings = zhn_meanings.div
        for p_node in zhn_meanings.find_all(name='p', recursive=False):
            if p_node.strong.string is not None:
                result += str(p_node.strong.string)
                result += ' '
            if p_node.span.string is not None:
                result += str(p_node.span.string)
                result += '|'

        return result
    else:
        zhn_meanings = soup.find(attrs={'id': 'fanyi-content'})
        if zhn_meanings is None:
            return None
        else:
            result = str(zhn_meanings.string)
            return result.strip() + '|'