Note that there are some explanatory texts on larger screens.

plurals
  1. POHow Does Drupal 7 Render Out a Page?
    primarykey
    data
    text
    <p>How does Drupal 7 render out a page? What's its equivalent to an MVC's view system. </p> <p>When it comes to the rendering out the final HTML page for a request, most PHP frameworks (MVC based) I've worked with take an approach where a top-level layout/page PHP file sets out the basic document structure, and then renders our various sub-views via includes or view rendering methods.</p> <pre><code>//Simplified version Page.phtml Head.phtml Body.phtml Banner.phtml Topnav.phtml Left.phtml Content.phtml Footer.phtml </code></pre> <p>I'm a little confused as to Drupal's take on this. I'm reading through Pro Drupal Development, and it starts off in similar territory with a <code>page.tpl.php</code>. However, it glosses over how the theme engine (is that the right term?) gets the various parts of PHP into this page (not a criticism, the book's taking an approach that different from the path I'm on). </p> <p>Also, the Drupal 7 themes don't seem to have the <code>page.tpl.php</code> file, so its not clear (to me) where the page skeleton comes from. Also, from what I've read it seems like "Blocks" are involved, but it's not clear to me if "Blocks" makeup the entire page, or if blocks are something used selectively by themes.</p> <p>So, working from high level concepts (or get as detailed as you'd like), how does Drupal 7 render out a page?</p> <p><em>I realize you can, and probably should, start with Drupal without understand how everything ties together. I'm specifically trying to learn how the various Drupal systems come together. Apologies to people tired of reading this disclaimer!</em></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload