Akelos Framework v1 forum archive. This forum is no longer maintained. To report bugs please visit https://github.com/akelos/akelos/issues
    • CommentAuthorpweil
     
    Can anyone get template rendering to apply a layout?

    First, the "template root" render uses seems to be app/views/current_directory (based on the controller), rather than app/views. Second, I cannot get any layout to be applied, even though it is explicitly set in the controller. All I get is the template and no layout. I've also tried rendering a file instead, using a filepath, but the result is the same.

    In AkActionController it says:

    * === Rendering a template
    *
    * Template rendering works just like action rendering except that it takes a
    * path relative to the template root.
    * The current layout is automatically applied.
    *
    * * Renders the template located in app/views/weblog/show.tpl
    * $this->render(array('template'=>'weblog/show'));
    • CommentAuthorKaste
     

    From looking at the code, the documentation is incorrect. renderTemplate does not apply a layout.

    Bug? or missing_feature?

    • CommentAuthorhpatoio
     
    Hej Kaste.

    I guess it's a bug.

    Read here

    http://forum.akelos.org/discussion/453/render-a-different-template/

    --
    Simone