Calling a non-default method of my controller in my views?

Hello everyone, I have a messages_controller, inside this controller, among all the default methods I have a tweet method that sends the message to twitter, and aside the 'edit' and 'destroy' links I want a 'tweet' one. However, I don't know how invoke this method in my app/ views/messages/index.html.erb and I don't know if I must add something in config/routes.rb, if you know, please help me!

Thanks!

Rodrigo Alves Vieira!

Assuming you’re using Rails 3, read the guide on routing: http://guides.rubyonrails.org/routing.html. It’s very helpful and will explain how to connect a new action like you have here. The upshot is to route it as a member action that can be invoked on a specific Message. Then you’ll have a nice named route you can use in your view, like tweet_message_path(@message).