What are these called?


#1

Hello,

I’ve looking at a tutorial in a web page and i saw a sample:

def logout
session[:user] = nil
redirect_to :controller => :user, :action => :index
end

def register
if request.post?
@user = User.new(params[:user])
if @user.save
redirect_to :action => :account_creation_success, :id => @user
end
end
end

i want to learn the names of these to search and learn about them?

    ":index" and ":account_creation_success"

what are they called?


#2

:index and :whatever are called symbols.

The Pickaxe book discusses there in depth.


#3

This code might not work. These are just symbols, but Rails has
always insisted on strings for controller and action names.