Topic: Ruby syntax question
<%= link_to recipe.title,
:action => "show",
:id => recipe.id %>
That code is used in a ruby on rails tutorial on this page: http://www.onlamp.com/pub/a/onlamp/2005 tml?page=2
I understand what is happening , but
I don't understand the syntax involved.
This is more of a Ruby question than a Ruby on Rails question, but I'd
appreciate it if you could shine some light on the syntax rules here.
Is link_to a method with the next three comma-separated terms being the paramaeters?
And I thought => was hash syntax used to bind keys to values, but are the last two
terms part of hashes? And what's with the weird colon in front of the names?
I've been skimming this book: http://www.rubycentral.com/book/
But I've really been bouncing around and not reading it front to back. So maybe
if you could just tell me what subject I should look into to figure this out.(e.g. method calls, hash syntax, etc.)