The nomenclature of programming languages

By | July 23, 2014

I’m going through the Rail for Zombies tutorial, and I’ve come across another thing that I’m struggling with.

In a Controller I have this code

respond_to do |format|
format.xml { render xml: @zombie}

Why isn’t it or respond_to :do or respond_to do: ?

Why isn’t it format xml or format(xml) or format :xml ?

And how about render.xml or render :xml ?

The video suggests spending a few minutes looking at the Ruby tutorial at, but that haven’t made this significantly easier.

But there’s still so many holes and I have no clue if I’m lacking Ruby knowledge or if Rails is being taught to me in some sort of incomplete manner.

Leave a Reply

Your email address will not be published. Required fields are marked *