TT3: /home/abw/web/london/tt3/slides/examples/slot_layout.tt3

Template Source

<div id="header"> %% slot header This is the default header %% end </div> <div id="content"> %% slot content This is the default content %% end </div> <div id="footer"> %% slot footer This is the default footer %% end </div> --EOF--

Source Tokens

text@0<div id="header">\n
tag_start@18%%
whitespace@20
command slot@22slot
whitespace@26
filename@27header
tag_end@33\n
text@34 This is the default header\n
tag_start@69%%
whitespace@71
end@73end
tag_end@76 \n
text@78</div>\n\n<div id="content">\n
tag_start@105%%
whitespace@107
command slot@109slot
whitespace@113
filename@114content
tag_end@121\n
text@122 This is the default content\n
tag_start@158%%
whitespace@160
end@162end
tag_end@165\n
text@166</div>\n\n<div id="footer">\n
tag_start@192%%
whitespace@194
command slot@196slot
whitespace@200
filename@201footer
tag_end@207\n
text@208 This is the default footer\n
tag_start@243%%
whitespace@245
end@247end
tag_end@250 \n
text@252</div>\n
eof@259

Parse Tree

text@0<div id="header">\n
slot keyword@22slot
Name
filename element@27header
Block
text@34 This is the default header\n
text@78</div>\n\n<div id="content">\n
slot keyword@109slot
Name
filename element@114content
Block
text@122 This is the default content\n
text@166</div>\n\n<div id="footer">\n
slot keyword@196slot
Name
filename element@201footer
Block
text@208 This is the default footer\n
text@252</div>\n

Variables Used

Generated Output

<div id="header"> This is the default header </div> <div id="content"> This is the default content </div> <div id="footer"> This is the default footer </div>