• Resolved the_lar

    (@the_lar)


    Hi All,

    I’m using the Sage starter theme by Roots.io for a new site which now uses laraval’s Blade templating engine.

    I’m trying to set up my own custom template using the shortcode:

    [theme-my-login login_template=”my-login-form.php”]

    I’ve tried duplpicating the login-form.php template renaming it to my-login-form.php then placing the file in the theme root directory and where the other templates are stored in Sage 9 which is in the resources/views directory, neither locations seems to work. Does anyone have any idea how I could get this to work with Sage 9?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jeff Farthing

    (@jfarthing84)

    TML looks in any of the following places for the templates:

    
    $template_paths = apply_filters( 'tml_template_paths', array(
    	get_stylesheet_directory() . '/theme-my-login',
    	get_stylesheet_directory(),
    	get_template_directory() . '/theme-my-login',
    	get_template_directory(),
    	THEME_MY_LOGIN_PATH . '/templates'
    ) );
    

    As you can see, there is also a filter you can use to add additional paths, if needed.

    Thread Starter the_lar

    (@the_lar)

    I’m just guessing but I think that roots/sage must redefine the result of get_stylesheet_directory() and get_template_directory() – from further playing around I did get it to work by putting the templates in the resources/ folder of Sage 9. I guess this must be get_template_directory() so theoretically if I created a subdirectory resources/theme-my-login – they would also work in there too.

    @the_lar, have you found a way to put the TML template files inside the resources/views folder?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Custom login template with Sage 9 theme?’ is closed to new replies.