<% if taxon.children.length != 0 %>
  <ul>
    <% taxon.children.each do |child| %>
      <li id="<%= child.id %>" rel="taxon">
        <a style="background-image: url(<%= child.icon.url %>);" href="#"><%= child.name %></a>
        <% if child.children.length > 0 %>
          <%= render :partial => 'taxon', :locals => { :taxon => child } %>
        <% end %>
      </li>
    <% end %>
  </ul>
<% end %>
