Zřetezeni layout pro moduly
- Fires
- Člen | 97
Zdravim, pustil sem se do modulu a resim ted problem s vycenasobnym layautem
..
Mam layouty – app/AdminModule/templates/@layout.latte
app/FrontModule/templates/@layout.latte
app/templates/@layout.latte
Potrebuji aby app/templates/@layout.latte tvoril zaklad tzn ( header +
footer ) ..
Od nej aby dedily app/AdminModule/templates/@layout.latte – pridal
menu pro adminy + include #content
app/FrontModule/templates/@layout.latte – pridal menu pro front +
include #content
Zkousel sem nekolik hodin hledat a procitat sablony a vsechno .. Reseni co by melo fungovat mi vyhazuje error.
app/templates/@layout.latte
<!DOCTYPE html>
<html>
<head>
...
</head>
<body>
<div n:foreach="$flashes as $flash" class="flash {$flash->type}">{$flash->message}</div>
{include #content}
</body>
</html>
app/FrontModule/templates/@layout.latte
{extends ../../templates/@layout.latte}
<p> testovaci </p>
vyhazuje chybu
Parse Error
syntax error, unexpected '.'
Chapu to dedeni nekolika layoutu uplne spatne? Nemuzete me nekdo nakopnout
spravnym smerem ?
Zkousel sem uz nekolik uprav ale vzdy bud celou praci odvedl jeden layout nebo
druhy ..
Editoval Fires (15. 2. 2011 19:06)
- Fires
- Člen | 97
Furt nic , opet to testovaci nevykresly … zkousel sem i #content i content …
app/FrontModule/templates/@layout.latte
{extends '../../templates/@layout.latte'}
{block #content}
<p> testovaci </p>
app/templates/@layout.latte
<!DOCTYPE html>
<html>
<head>
...
</head>
<body>
<div n:foreach="$flashes as $flash" class="flash {$flash->type}">{$flash->message}</div>
{include #content}
</body>
</html>