def break_name(name, length):
    """Take a long technology name string and break it across multiple lines"""
    name_breaks = len(name) / length
    if name_breaks > 1:
        initial_name = name
        break_buffer = 0
        for name_break in range(1, int(name_breaks) + 1):
            breakpoint = initial_name.rfind(' ', name_break * length - 10, 
                name_break * length)
            if breakpoint != -1:
                breakpoint += break_buffer
                name = name[:breakpoint].rstrip() + '<br>' + name[breakpoint:
                    ].lstrip()
                break_buffer += 4
            else:
                breakpoint = length * name_break + break_buffer
                name = name[:breakpoint].rstrip() + '...<br>' + name[breakpoint
                    :].lstrip()
                break_buffer += 7
    return name
