def li_loop_for_terms(arr, term_type, initial = 'initial')

      article_url = Setting.get('articles_slug')

      html = '<ul class="' + initial + '">'
      arr.each do |key, val|
        html += "<li><a href='#{site_url}#{article_url}/#{term_type}#{key.structured_url}'>#{key.name}</a>"
        html += li_loop_for_terms(val, term_type, 'sub') unless val.blank?
      end
      html += '</ul>'

      render :inline => html

    end
def li_loop_for_terms(arr, term_type, initial = 'initial')

      article_url = Setting.get('articles_slug')

      html = '<ul class="' + initial + '">'
      arr.each do |key, val|
        html += "<li><a href='#{site_url}#{article_url}/#{term_type}#{key.structured_url}'>#{key.name}</a>"
        html += li_loop_for_terms(val, term_type, 'sub') unless val.blank?
      end
      html += '</ul>'

      render :inline => html

    end
Returns a list of the given data, but puts children records in the loop
 Params:
 +arr+:: array that you want to list through to create the list