I had too a logout button in the template, inside a h:form but i don't remember if i get problem.
You can check:
1) If the web page was shown, open the source code (from browser) and investigate if the form and the link was correctly rendered;
2) Are there nested forms?
3) Check if the LoginBean was created: are there problem with the constructor or the postConstructor? For experience, most of times I had that problem because i made error in the constructor of beans. To test it, create a property String test and a getter method and put it in the template and in the included page.
Another way, you can simply put the form and the button in a page like _logout.xhtml and use inclusion in template
This solution provided smaller xhtml pages and focused on a concern... if you want to change logout in a button, you need only to modify _logout.xhtml
NB: pay attention with primefaces and multiple forms, with prepended id on component ;)