   # TODO - ABSTRACT INTO SEPARATE VIEW
   # FOR RESULT COUNTR AND ORDER CONTROLS
   # Append total result count
-
   bottomContainer = '<div class=bottomline></div>'
-
   bottom = $(bottomContainer)
   countHtml = _.template(settings.countTemplate, count: settings.currentResults.length or 0)
   $(bottom).append(countHtml)
 
 
   # generate the "order by" options:
-  ordertemplate = _.template(settings.orderByTemplate)
+
+  orderByTemplate = '<div class=orderby><span class="orderby-title">Sort by: </span><ul><% _.each(options, function(value, key) { %>' + '<li class=orderbyitem id=orderby_<%= key %>>' + '<%= value %> </li> <% }); %></ul></div>'
+
+  ordertemplate = _.template(orderByTemplate)
   itemHtml = $(ordertemplate('options': settings.orderByOptions))
   $(bottom).append itemHtml
   $(settings.facetElement).append bottom


  # Append deselect filters button
  # TODO - abstract into Backbone.View
  deselect = $(settings.deselectTemplate).click((event) ->
    settings.state.filters = {}
    jQuery.facetUpdate()
    return

  # $(settings.resultElement).append itemHtml

  # Append "MoreButton"
  showMoreTemplate = '<a id=showmorebutton>Show more</a>'
  # TODO - we will _probably_ paginate using BB.Mn
  # TODO - pagination
  # if !moreButton
  #   moreButton = $(showMoreTemplate).click(showMoreResults)
  #   $(settings.resultElement).after moreButton
  # # ???/
  # if settings.state.shownResults == 0
