Hello everyone,
For some time I was studying Ruby on Rails, Active Record ideology and
other thing related with RoR right now I still know a lot more about
PHP than RoR. I am almost ready to start writing websites using RoR
and get more experience. But I still have some questions before
starting and I can’t start without answers.
If you could simply answer some of them, would be great.
-
Reading about ActiveRecord (RoR) I noticed that there are some
special tables columns which are filled/updated automatically. These
are a few: created_at, created_on, updated_at, updated_on. There I
could get the full list of these columns/fields names and how
everything works? I don’t want to write code like a blind man. -
Cookies could be accessed using cookies[:my_coockie], using this I
can read/create/update cookie? -
The hole RoR application for me has one hole at least I think so at
this point. The are controllers, actions but what about the main page?
RoR firstly looks in the public directory and loads HTML or other
files if it exists. There are index.htm(l), but how I can make dynamic
index page? Rails/Ruby code inside index.htm(l) as I assume won’t
work. So the first page must be only static? Or I should redirect user
to some controller/action in index? -
What is test directory for? And /libs/taks? It looks like this part
isn’t clear for me. -
I noticed %w[someting_inside], but what that %w does and where I
could read more about it? -
Sorry for this one, but I am busy looking for some other answers
using google and I don’t have much time. There I could find pre-
defined variables list?
Thanks, I really appreciate for the help. I will learn it!