Hi Cymon, On Sun, Sep 13, 2015 at 1:11 AM, Cymon <cymon.ML@gmail.com> wrote:
The solution I usually use is keeping routes using different layout in different Apps. In my opinion, if you have something important as the layout changing, It's not wrong to keep these routes in different modules.
At my project there is only 1 application and main layout is set at config.yml. If I use 2nd application, will it have a different config file?
For the situation described in the mail, where we have just to turn off links, probably an IF in the template should be enough...
Simone Faré http://perlishscrewdriver.blogspot.com http://www.strehler-cms.org/
Il giorno Sat, 12 Sep 2015 12:12:45 -0700 Hermann Calabria <hermann@ivouch.com> ha scritto:
Here's a recipe I created some time ago for setting different layouts for different routes, including no layout at all.
http://stackoverflow.com/questions/18198270/more-than-one-layout-wrapper-wit...
Sent from my mobile. Please excuse brevity & typos.
On Sep 12, 2015, at 11:49 AM, Kadir Beyazlı <kadirbeyazli@gmail.com> wrote:
Hi John,
Yes it worked as follow, thanks.
template 'login', { path => param('requested_path') }, { layout => undef };
On Sat, Sep 12, 2015 at 9:33 PM, John J. McDermott, CPLP <jjm@jkintl.com> wrote: To unset it just for login, try
get '/login' => sub { template 'login', { path => param('requested_path') }, undef; };
See http://search.cpan.org/~sukria/Dancer2-0.10/lib/Dancer2/Manual.pod#template
I believe setting "layout" is global. --john
On 9/12/2015 12:20 PM, Kadir Beyazlı wrote:
Hi All,
Following worked, but this time main layout was not loaded at other routes either. I want main layout not to be loaded for only /login route.
get '/login' => sub { set 'layout' => undef; template 'login', { path => param('requested_path') }; };
On Sat, Sep 12, 2015 at 9:15 PM, Kadir Beyazlı <kadirbeyazli@gmail.com> wrote:
Hi All,
I tried following but it did not work, I need something similar to it.
get '/login' => sub { config->{layout} = undef; template 'login', { path => param('requested_path') }; };
On Sat, Sep 12, 2015 at 9:01 PM, Kadir Beyazlı <kadirbeyazli@gmail.com> wrote:
Hi All,
I think I saw solution at mails but could not find at my search so I have to ask here.
I set main layout. But I don't want main layout to be loaded at route /login. Is it possible disabling main layout at route /login although I am using template in it?
get '/login' => sub { template 'login', { path => param('requested_path') }; };
-- Kadir Beyazlı GSM : +90 535 821 50 00
-- Kadir Beyazlı Computer Engineer GSM : +90 535 821 50 00
-- John J. McDermott, CPLP Learning and Performance Consultant jjm at jkintl.com 575/737-8556 Check out my security blog posts Add an A for the Arts To STEM and get STEAM and a strong engine to move forward.
_______________________________________________ dancer-users mailing list dancer-users@dancer.pm http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
-- Kadir Beyazlı Computer Engineer GSM : +90 535 821 50 00 _______________________________________________ dancer-users mailing list dancer-users@dancer.pm http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
dancer-users mailing list dancer-users@dancer.pm http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
_______________________________________________ dancer-users mailing list dancer-users@dancer.pm http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
-- Kadir Beyazlı Computer Engineer GSM : +90 535 821 50 00