def get_text_between_substrings(input_str, left_sub, right_sub):
    """Returns the text located between two given substrings.

    Args:
        input_str: String. The text will be extracted from it
        left_sub: String. The substring on the left of the text
        right_sub: String. The substring on the right of the text

    Returns:
        String: the text between the substrings (or '' if not found)
    """
    res = ""
    if left_sub in input_str and right_sub in input_str:
        if input_str.find(left_sub) < input_str.find(right_sub):
            right_part = input_str.split(left_sub)[1]
            res = right_part.split(right_sub)[0].strip()
    return res