I am a beginner to ruby on rails; just doing a simple blog. I did what I think is needed:

(1) added the page and action under route.rb 

> 
> get "/posts/index" => "posts#index", as: :index
> 
> 
> get "/posts/new" => "posts#new", as: :new
> 
> 
> 

(2) and created the controller `posts_controller.rb`

(3) and also created the new pages:

* index.html.erb
* new.html.erb

But I got an error saying "The webpage is not available".

What can be the reason of this error?

Thanks in advance.