<commit_before>{* $Header: /cvsroot/tikiwiki/tiki/templates/modules/mod-login_box.tpl,v 1.41 2007-04-19 22:34:34 mose Exp $ *}
{if !isset($tpl_module_title)}{assign var=tpl_module_title value="{tr}Login{/tr}"}{/if}
{tikimodule title=$tpl_module_title name="login_box" flip=$module_params.flip decorations=$module_params.decorations}

    {if $user}
      {tr}logged as{/tr}: {$user|userlink}<br />
      <a class="linkmodule" href="tiki-logout.php">{tr}Logout{/tr}</a><br />
      {if $tiki_p_admin eq 'y'}
        <form action="{$login_url}" method="post"{if $desactive_login_autocomplete eq 'y'} autocomplete="off"{/if}>
        <label for="login-switchuser">{tr}user{/tr}:</label>
        <input type="hidden" name="su" value="1" />
        <input type="text" name="username" id="login-switchuser" size="8" />
        <input type="submit" name="actsu" value="{tr}set{/tr}" />
        </form>
      {/if}
      {elseif $auth_method eq 'cas' && $showloginboxes neq 'y'}
		<b><a class="linkmodule" href="tiki-login.php?user">{tr}Login through CAS{/tr}</a></b>
		{if $cas_skip_admin eq 'y'}
		<br /><a class="linkmodule" href="tiki-login_scr.php?user=admin">{tr}Login as admin{/tr}</a>
      {/if}
      {elseif $auth_method eq 'shib' && $showloginboxes neq 'y'}
		<b><a class="linkmodule" href="tiki-login.php">{tr}Login through Shibboleth{/tr}</a></b>
		{if $shib_skip_admin eq 'y'}
		<br /><a class="linkmodule" href="tiki-login_scr.php?user=admin">{tr}Login as admin{/tr}</a>
      {/if}
    {else}
     <form name="loginbox" action="{$login_url}" method="post" {if $feature_challenge eq 'y'}onsubmit="doChallengeResponse()"{/if}{if $desactive_login_autocomplete eq 'y'} autocomplete="off"{/if}> 
     {if $feature_challenge eq 'y'}
     <script type='text/javascript' src="lib/md5.js"></script>   
     {literal}
     <script type='text/javascript'>
     <!--
     function doChallengeResponse() {
       hashstr = document.loginbox.user.value +
       document.loginbox.pass.value +
       document.loginbox.email.value;
       str = document.loginbox.user.value + 
       MD5(hashstr) +
       document.loginbox.challenge.value;
       document.loginbox.response.value = MD5(str);
       document.loginbox.pass.value='';
       /*
       document.login.password.value = "";
       document.logintrue.username.value = document.login.username.value;
       document.logintrue.response.value = MD5(str);
       document.logintrue.submit();
       */
       document.loginbox.submit();
       return false;
     }
     // -->
    </script>
    {/literal}
     <input type="hidden" name="challenge" value="{$challenge|escape}" />
     <input type="hidden" name="response" value="" />
     {/if}
      <table border="0">
      <tr>
        <td>
          <table>
          <tr><td class="module"><label for="login-user">{tr}user{/tr}:</label></td></tr>
		{if $loginuser eq ''}
          <tr><td><input type="text" name="user" id="login-user" size="20" /></td></tr>
	  <script type="text/javascript">document.getElementById('login-user').focus();</script>
		{else}
		  <tr><td><input type="hidden" name="user" id="login-user" value="{$loginuser}" /><b>{$loginuser}</b></td></tr>
		{/if}
<script type="text/javascript">document.getElementById('login-user').focus();</script>
          {if $feature_challenge eq 'y'} <!-- quick hack to make challenge/response work until 1.8 tiki auth overhaul -->
          <tr><td class="module"><label for="login-email">{tr}email{/tr}:</label></td></tr>
          <tr><td><input type="text" name="email" id="login-email" size="20" /></td></tr>
          {/if}
          <tr><td class="module"><label for="login-pass">{tr}pass{/tr}:</label></td></tr>
          <tr><td><input type="password" name="pass" id="login-pass" size="20" /></td></tr>
          <tr><td><input type="submit" name="login" value="{tr}login{/tr}" /></td></tr>
          {if $rememberme ne 'disabled'}
            {if $rememberme eq 'always'}
              <input type="hidden" name="rme" id="login-remember" value="on"/>
            {else}
              <tr><td class="module"><label for="login-remember">{tr}Remember me{/tr}</label> <input type="checkbox" name="rme" id="login-remember" value="on"/></td></tr>
            {/if}
          {/if}
          <tr>
          {if $forgotPass eq 'y' and $allowRegister eq 'y' and $change_password eq 'y'}
            <td  class="module" valign="bottom">[ <a class="linkmodule" href="tiki-register.php" title="{tr}Click here to register{/tr}">{tr}register{/tr}</a> | <a class="linkmodule" href="tiki-remind_password.php" title="{tr}Click here if you've forgotten your password{/tr}">{tr}I forgot my pass{/tr}</a> ]</td>
          {/if}
          {if $forgotPass eq 'y' and $allowRegister ne 'y' and $change_password eq 'y'}
            <td  class="module" valign="bottom"><a class="linkmodule" href="tiki-remind_password.php" title="{tr}Click here if you've forgotten your password{/tr}">{tr}I forgot my pass{/tr}</a></td>
          {/if}
          {if ($forgotPass ne 'y' or $change_password ne 'y') and $allowRegister eq 'y'}
            <td  class="module" valign="bottom"><a class="linkmodule" href="tiki-register.php" title="{tr}Click here to register{/tr}">{tr}register{/tr}</a></td>
          {/if}
          {if ($forgotPass ne 'y' or $change_password ne 'y')and $allowRegister ne 'y'}<commit_msg>[MOD] shortened input field size for user/pass<commit_after>{* $Header: /cvsroot/tikiwiki/tiki/templates/modules/mod-login_box.tpl,v 1.42 2007-05-17 07:14:08 nkoth Exp $ *}
{if !isset($tpl_module_title)}{assign var=tpl_module_title value="{tr}Login{/tr}"}{/if}
{tikimodule title=$tpl_module_title name="login_box" flip=$module_params.flip decorations=$module_params.decorations}

    {if $user}
      {tr}logged as{/tr}: {$user|userlink}<br />
      <a class="linkmodule" href="tiki-logout.php">{tr}Logout{/tr}</a><br />
      {if $tiki_p_admin eq 'y'}
        <form action="{$login_url}" method="post"{if $desactive_login_autocomplete eq 'y'} autocomplete="off"{/if}>
        <label for="login-switchuser">{tr}user{/tr}:</label>
        <input type="hidden" name="su" value="1" />
        <input type="text" name="username" id="login-switchuser" size="8" />
        <input type="submit" name="actsu" value="{tr}set{/tr}" />
        </form>
      {/if}
      {elseif $auth_method eq 'cas' && $showloginboxes neq 'y'}
		<b><a class="linkmodule" href="tiki-login.php?user">{tr}Login through CAS{/tr}</a></b>
		{if $cas_skip_admin eq 'y'}
		<br /><a class="linkmodule" href="tiki-login_scr.php?user=admin">{tr}Login as admin{/tr}</a>
      {/if}
      {elseif $auth_method eq 'shib' && $showloginboxes neq 'y'}
		<b><a class="linkmodule" href="tiki-login.php">{tr}Login through Shibboleth{/tr}</a></b>
		{if $shib_skip_admin eq 'y'}
		<br /><a class="linkmodule" href="tiki-login_scr.php?user=admin">{tr}Login as admin{/tr}</a>
      {/if}
    {else}
     <form name="loginbox" action="{$login_url}" method="post" {if $feature_challenge eq 'y'}onsubmit="doChallengeResponse()"{/if}{if $desactive_login_autocomplete eq 'y'} autocomplete="off"{/if}> 
     {if $feature_challenge eq 'y'}
     <script type='text/javascript' src="lib/md5.js"></script>   
     {literal}
     <script type='text/javascript'>
     <!--
     function doChallengeResponse() {
       hashstr = document.loginbox.user.value +
       document.loginbox.pass.value +
       document.loginbox.email.value;
       str = document.loginbox.user.value + 
       MD5(hashstr) +
       document.loginbox.challenge.value;
       document.loginbox.response.value = MD5(str);
       document.loginbox.pass.value='';
       /*
       document.login.password.value = "";
       document.logintrue.username.value = document.login.username.value;
       document.logintrue.response.value = MD5(str);
       document.logintrue.submit();
       */
       document.loginbox.submit();
       return false;
     }
     // -->
    </script>
    {/literal}
     <input type="hidden" name="challenge" value="{$challenge|escape}" />
     <input type="hidden" name="response" value="" />
     {/if}
      <table border="0">
      <tr>
        <td>
          <table>
          <tr><td class="module"><label for="login-user">{tr}user{/tr}:</label></td></tr>
		{if $loginuser eq ''}
          <tr><td><input type="text" name="user" id="login-user" size="14" /></td></tr>
	  <script type="text/javascript">document.getElementById('login-user').focus();</script>
		{else}
		  <tr><td><input type="hidden" name="user" id="login-user" value="{$loginuser}" /><b>{$loginuser}</b></td></tr>
		{/if}
<script type="text/javascript">document.getElementById('login-user').focus();</script>
          {if $feature_challenge eq 'y'} <!-- quick hack to make challenge/response work until 1.8 tiki auth overhaul -->
          <tr><td class="module"><label for="login-email">{tr}email{/tr}:</label></td></tr>
          <tr><td><input type="text" name="email" id="login-email" size="14" /></td></tr>
          {/if}
          <tr><td class="module"><label for="login-pass">{tr}pass{/tr}:</label></td></tr>
          <tr><td><input type="password" name="pass" id="login-pass" size="14" /></td></tr>
          <tr><td><input type="submit" name="login" value="{tr}login{/tr}" /></td></tr>
          {if $rememberme ne 'disabled'}
            {if $rememberme eq 'always'}
              <input type="hidden" name="rme" id="login-remember" value="on"/>
            {else}
              <tr><td class="module"><label for="login-remember">{tr}Remember me{/tr}</label> <input type="checkbox" name="rme" id="login-remember" value="on"/></td></tr>
            {/if}
          {/if}
          <tr>
          {if $forgotPass eq 'y' and $allowRegister eq 'y' and $change_password eq 'y'}
            <td  class="module" valign="bottom">[ <a class="linkmodule" href="tiki-register.php" title="{tr}Click here to register{/tr}">{tr}register{/tr}</a> | <a class="linkmodule" href="tiki-remind_password.php" title="{tr}Click here if you've forgotten your password{/tr}">{tr}I forgot my pass{/tr}</a> ]</td>
          {/if}
          {if $forgotPass eq 'y' and $allowRegister ne 'y' and $change_password eq 'y'}
            <td  class="module" valign="bottom"><a class="linkmodule" href="tiki-remind_password.php" title="{tr}Click here if you've forgotten your password{/tr}">{tr}I forgot my pass{/tr}</a></td>
          {/if}
          {if ($forgotPass ne 'y' or $change_password ne 'y') and $allowRegister eq 'y'}
            <td  class="module" valign="bottom"><a class="linkmodule" href="tiki-register.php" title="{tr}Click here to register{/tr}">{tr}register{/tr}</a></td>
          {/if}
          {if ($forgotPass ne 'y' or $change_password ne 'y')and $allowRegister ne 'y'}
{'fraction_non_alphanumeric': 0.20318613750698714, 'fraction_numerical': 0.005962362586174772, 'mean_word_length': 3.385212418300654, 'pattern_counts': {'":': 0, '<': 223, '<?xml version=': 0, '>': 223, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '506429', 'n_tokens_mistral': 3763, 'n_tokens_neox': 3616, 'n_words': 699}