anchor.diff:        jQuery('.ui-autocomplete-input').addClass('input-text');
       }
     }
  -</script>+</script>
  +
  +<script type="text/javascript">
  +  var tags= <%= Tag.all.map(&:name).to_json  %>;
  +  var myTextArea = jQuery('#auto-text').tagify();
  +
  +  myTextArea.tagify('inputField').autocomplete({
  +    source: tags,
  +    position: { of: myTextArea.tagify('containerDiv') },
  +    close: function(event, ui) { myTextArea.tagify('add'); }
  +  });
  +
  +  jQuery("#idea_form").submit(function(e){
  +    var new_values = jQuery(".tagify-container input:first").val();
  +    jQuery.each(new_values.split(","),function(i,data){
  +      myTextArea.tagify("add",data);
  +    });
  +    myTextArea.tagify("serialize");
  +  });
  +  
  +</script>
  +<% end %>
positive.code:   })
  </script>
  
  
  
  
  <div id ="share" class="section">
  
negative.code:             <strong><%=t('menu.tags')%></strong>
              <small> <%=t("seperate_with_coma")%></small>
            </label>
            <%= render :partial => 'ideas/tag_editor', :locals => { :f => f }%>
            <%= f.collection_select :current_id, Current.all_except_default, :id, :title , {:include_blank=>'Hovedveje ...'}, :style => "width:196px;"%>
          </div>
  
  