frontchannel-logout.ftl 1.1 KB

123456789101112131415161718192021222324252627282930
  1. <#import "template.ftl" as layout>
  2. <@layout.registrationLayout; section>
  3. <#if section = "header">
  4. <script>
  5. document.title = "${msg("frontchannel-logout.title")}";
  6. </script>
  7. ${msg("frontchannel-logout.title")}
  8. <#elseif section = "form">
  9. <p>${msg("frontchannel-logout.message")}</p>
  10. <ul>
  11. <#list logout.clients as client>
  12. <li>
  13. ${client.name}
  14. <iframe src="${client.frontChannelLogoutUrl}" style="display:none;"></iframe>
  15. </li>
  16. </#list>
  17. </ul>
  18. <#if logout.logoutRedirectUri?has_content>
  19. <script>
  20. function readystatechange(event) {
  21. if (document.readyState=='complete') {
  22. window.location.replace('${logout.logoutRedirectUri}');
  23. }
  24. }
  25. document.addEventListener('readystatechange', readystatechange);
  26. </script>
  27. <a id="continue" class="btn btn-primary" href="${logout.logoutRedirectUri}">${msg("doContinue")}</a>
  28. </#if>
  29. </#if>
  30. </@layout.registrationLayout>