added autolink gem to site. We should integrate this with the forums as well? And pretty much any text field?

This commit is contained in:
Room5-Joey 2014-05-13 17:31:03 -07:00 committed by Luke Barratt
parent ed71ad5344
commit 463b2d7e23
2 changed files with 2 additions and 1 deletions

View file

@ -36,6 +36,7 @@ gem 'font-awesome-sass', '~> 4.1.0.0'
gem 'bourbon', '~> 3.1.8' gem 'bourbon', '~> 3.1.8'
gem 'neat', '~> 1.6.0' gem 'neat', '~> 1.6.0'
gem 'haml' gem 'haml'
gem 'rails_autolink', '~> 1.1.5'
group :assets do group :assets do
gem 'uglifier', '~> 2.5.0' gem 'uglifier', '~> 2.5.0'

View file

@ -9,7 +9,7 @@
</div> </div>
<div class="message"> <div class="message">
<div class="contents"> <div class="contents">
<%= shoutmsg.text %> <%= auto_link(shoutmsg.text, :html => { :target => '_blank' }) %>
<% if shoutmsg.can_destroy? cuser %> <% if shoutmsg.can_destroy? cuser %>
<%= link_to icon('times'), shoutmsg, method: :delete, class: 'destroy' %> <%= link_to icon('times'), shoutmsg, method: :delete, class: 'destroy' %>
<% end %> <% end %>