Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/templates/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Templates 用于不同任务的多个模板_Templates_Symfony_Fosuserbundle - Fatal编程技术网

Templates 用于不同任务的多个模板

Templates 用于不同任务的多个模板,templates,symfony,fosuserbundle,Templates,Symfony,Fosuserbundle,我需要得到两个典型的授权,注册不同的布局,并显示在弹出窗口 Facebook和Facebook的一个很好的例子 但是,在我的例子中,名为link/oauth/v2/auth,安全性自动重定向到登录页面 My security.yml: oauth_token: pattern: ^/oauth/v2/token security: false oauth_authorize: pattern: ^/oauth/v2

我需要得到两个典型的授权,注册不同的布局,并显示在弹出窗口

Facebook和Facebook的一个很好的例子

但是,在我的例子中,名为link/oauth/v2/auth,安全性自动重定向到登录页面

My security.yml:

    oauth_token:
        pattern:    ^/oauth/v2/token
        security:   false

    oauth_authorize:
        pattern:    ^/oauth/v2/auth
        form_login:
            provider: fos_userbundle
        anonymous: true

    main:
        pattern: ^/
        form_login:
            provider: fos_userbundle
            csrf_provider: form.csrf_provider
            failure_forward: true
        logout:       true
        anonymous:    true
您是否可以用于登录表单

然后,您可以在登录表单上查看任意多个视图?

您是否可以使用登录表单

然后,您可以在登录表单打开时拥有任意多的视图