Ruby on Rails Sunday, February 28, 2016

I created a simple blog and I'm using paperclip to be able to add images
to a Post. I installed the 'themify-icons-rails' gem and what I want to
do is automatically add a picture icon next to the title of a post when
the post has a image that's been uploaded, to show that the post has a
image. I'm guessing I would need a If statement somewhere but I'm fairly
new to rails and I'm not sure where to put it.

<h2 class="ti-gallery"><%= link_to post.title, post %></h2> this adds
the "Ti-gallery" icon to every post.

Any Help will be greatly appreciated, Thank you before hand. Oh and one
more questions, Is rails Video friendly? i can't seem to find any
tutorials on uploading videos to a rails app.

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/050fa96f2643c768b05341ba1eefca74%40ruby-forum.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment