<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_text(item, tag, default=False):
 """ returns text content of an xml tag """

        try:
            xmlnode = item.getElementsByTagName(tag)[0].firstChild
        except IndexError as e:
            if default is not False:
                return default
            else:
                raise IndexError(e)

        if xmlnode is not None:
            return unicode(xmlnode.nodeValue)
        # empty tag
        else:
            return ''