title: Grails g:include can it be done?
body: <p>Im wondering if it is possible to use g:include to include only the body contents of a given page.</p>
  
  <p>Say i have a main layout page as follows:</p>
  
  <pre><code>&lt;html&gt;
    &lt;head&gt;
      &lt;title&gt;My start page&lt;/title&gt;
      &lt;g:layoutHead&gt;
    &lt;/head&gt;
    &lt;body&gt;
      &lt;g:layoutBody&gt;
    &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Then a main page (index.gsp)</p>
  
  <pre><code>&lt;html&gt;
    &lt;head&gt;
      &lt;!-- main layout reference --&gt;
      &lt;meta name="layout" content="main"/&gt;
    &lt;/head&gt;
    &lt;body&gt;
      THIS IS MY INDEX BODY CONTENT WITH AN INCLUDE
      &lt;g:include controller="book" action="list"/&gt;
      &lt;g:link controller="book" action="list"&gt;See the full list!&lt;/g:link&gt;
    &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>And finally the book/list page</p>
  
  <pre><code>&lt;html&gt;
    &lt;head&gt;
      &lt;!-- main layout reference --&gt;
      &lt;meta name="layout" content="main"/&gt;
    &lt;/head&gt;
    &lt;body&gt;
      &lt;table&gt;
      &lt;g:each in="${books}"&gt;
        &lt;tr&gt;
          &lt;td&gt;${it.author}&lt;/td&gt;
          &lt;td&gt;${it.title}&lt;/td&gt;
          &lt;td&gt;${it.price}&lt;/td&gt;
        &lt;/tr&gt;
      &lt;/g:each&gt;
      &lt;/table&gt;
    &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>So what i want to achieve is that the main page (index.gsp) only includes the table defined in the book/list page. However, when i try this it includes the entire html defined (<code>&lt;html&gt;</code> tags and all).</p>
  
  <p>is it possible to do this somehow? i've tried things like <code>&lt;g:include controller="book" action="list" view="someView.gsp"/&gt;</code> however this doesn't work. I really want to avoid having to add a book list logic to the "index controller" i want to reuse my existing controller.</p>
  
  <p>I can't be the first person out there having this usecase, what solutions have you guys come up with?</p>