My desired result was achieved...Thanks to your explanation above. I
wanted to have 1 html file linking the two header.html and footer.html
files. This example would be good to have in the book as it really
shows how the extend & includes work...at least it explained it better
for me (the book's example is too simple). I wanted to have 1 extend
at the top of the body.html file...here is what I did:

header.html
<html><head></head><body>

footer.html
</body></html>

main.html
{{include 'header.html'}} <div> my body stuff here </div>{{include
'footer.html'}}

body.html
{{extend 'main.html'}}<div> my body stuff here!</div>





On Oct 23, 11:02 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
> If this worked was a bug. You cannot extend two views.
>
> You can do this:
>
> layout.html
> <html><head></head><body>{{include}}</body></html>
>
> main.html
> {{extend 'layout.html'}} <div> my body stuff here </div>
>
> Or you can do this:
>
> header.html
> <html><head></head><body>
>
> footer.html
> </body></html>
>
> main.html
> {{include 'header.html'}} <div> my body stuff here </div>{{include
> 'footer.html'}}
>
> You can have various combination of the two but not the one you used.
> As explained in the manual the view hierarchy is a try. Extend points
> to a parent. A node in a tree cannot have two parents.
>
> On Oct 24, 12:37 am, b00m_chef <r...@devshell.org> wrote:
>
>
>
> > I noticed my app from a few releases back stopped working with regard
> > to the view. I had a file that extended 2 files (a header.html, and a
> > footer.html), it then included (in-between the 2 extends) a body.
>
> > Only the last extend will execute in the below main.html file in the
> > current release (1.87.3), however, in previous versions (a few months
> > ago) this would work as expected:
>
> > header.html
> > <html><head></head><body>{{include}}
>
> > footer.html
> > {{include}}</body></html>
>
> > main.html
> > {{extend 'header.html'}} <div> my body stuff here </div>{{extend
> > 'footer.html'}}

Reply via email to