title: HAML - how to create links so that they go to the right controllers?
body: <p>I have some links that I am trying to make work in HAML</p>
  
  <pre><code>  =link_to("My Disclosures", "") &lt;&lt; ' |'
    =link_to("Create Disclosure", "#") &lt;&lt; ' |'
    =link_to("My Programs", "#") &lt;&lt; ' |'
    =link_to("Log Out", "sign_out")
  </code></pre>
  
  <p>What I am not sure how to do is link to different controller actions that I have.</p>
  
  <p>Here are my routes:</p>
  
  <pre><code>scope :module =&gt; :mobile, :as =&gt; :mobile do
      constraints(:subdomain =&gt; /m/) do
        devise_for :users, :path =&gt; "", :path_names =&gt;
                 { :sign_in =&gt; "login", :sign_out =&gt; "logout",
                   :sign_up =&gt; "signup" },
                   :controllers =&gt; {:sessions =&gt; "mobile/sessions"}
  
        resources :home
  
        resources :disclosures # Will have new, get, look up a disclosure
      end
    end
  </code></pre>
  
  <p>So I thought my log_out path would have worked, but it isn't working it seems.</p>
  
  <p>Also, I have this very simple controller:</p>
  
  <pre><code>class Mobile::DisclosuresController &lt; ApplicationController
  
    def new
      Rails.logger.debug "-"*100
      Rails.logger.debug session.inspect
      Rails.logger.debug "-"*100
  
      respond_to do |format|
  
      end
    end
  
    def create
  
    end
  
    def destroy
  
    end
  end
  </code></pre>
  
  <p>But I am not sure how to make the HAML links so that they lead to the various controller actions I need to go to on get and post. Any help with how to correctly link to the controllers would be much appreciated.</p>