title: Rails 3.2.7 and link_to
body: <p>First of all, pretty new to Rails. I've been following a tutorial on using the 'link_to' command - basically, I have some links with text 'About Us', 'FAQ', 'Contact Us', and I want them to link to their respective pages.</p>
  <p>Following the tutorial, the code in my contact_us.html.erb file goes like this:</p>
  <pre><code>&lt;%= link_to &quot;About Us&quot;, {:controller =&gt; ‘static_pages’, :action =&gt; ’about_us’} %&gt;
  </code></pre>
  <p>My controller is called <code>static_pages_controller.rb</code> and I have an <code>about_us</code> method in that file, with no code in it:</p>
  <pre><code>def about_us
  end
  </code></pre>
  <p>My controller code is:</p>
  <pre><code>class StaticPagesController &lt; ApplicationController
    def about_us
    end
  
    def faq
    end
  
    def contact_us
    end
  
    def t_and_c
    end
  
    def t_and_c_competition
    end
  
    def show
    end
  end
  </code></pre>
  <p>I get the error:</p>
  <blockquote>
  <p>NameError in Static_pages#contact_us</p>
  <p>undefined local variable or method `‘static_pages'......etc</p>
  </blockquote>
  <p>Any ideas what's wrong? I think it might be because the tutorial is for ruby 1.8.6 and Rails  2.0.2, and I have Ruby 1.8.7 and Rails 3.2.7. I heard Rails is notorious for not being backwards compatible. Should I change my code? To what? Thanks for any help.</p>
  <p>C.</p>