]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/shamino_com/templates/signin.tmpl
rcs_id no longer makes sense with Subversion global version number
[SourceForge/phpwiki.git] / themes / shamino_com / templates / signin.tmpl
1 <?php // -*-php-*-
2 // rcs_id('$Id$');
3 // signin only implicitly by clicking "Edit"
4 if (empty($FORMNAME))
5     $FORMNAME = 'signin';
6 else
7     $NOFORM = true;
8 ?>
9 <?php if (empty($NOFORM)) { ?>
10   <form method="post" action="<?= $request->getPostURL() ?>" accept-charset="<?=$charset?>" name="<?=$FORMNAME?>">
11   <?= HiddenInputs($request->getArgs(), false, array('auth')) ?>
12 <?php }
13 if ($user->isAuthenticated()) {
14     $SignOutB = $WikiTheme->makeButton(_("Sign Out"), "javascript:SignOut();", 'wikiaction');
15     $SignOutJS = JavaScript('
16     document.write(\'<input type="hidden" name="auth[logout]" value="0" />\');
17     function SignOut() { 
18       var form = document.forms["'.$FORMNAME.'"];
19       form.elements["auth[logout]"].value = 1;
20       form.submit();
21     }
22     document.write(\''.AsXML($SignOutB).'\');');
23 ?>
24   <span class="signin"><?= fmt("Authenticated as %s", WikiLink($user->getAuthenticatedId(), 'auto')) ?>
25   <?=$SEP?><?=$SignOutJS?></span>
26   <noscript>
27     <span class="signin"><?= Button("submit:auth[logout]", _("Sign Out"), 'wikiaction') ?></span>
28   </noscript>
29 <?php } ?>
30 <?php if (empty($NOFORM)) { ?>
31   </form>
32 <?php } ?>