Changeset 2099 in ExiteCMS for trunk/includes/templates/main.login.tpl


Ignore:
Timestamp:
12/07/08 22:05:25 (3 years ago)
Author:
WanWizard
Message:

the authentication system now uses templates for login pages, so a new authentication method can supply it's own template with fields required for login

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/templates/main.login.tpl

    r2095 r2099  
    2424        <meta http-equiv='refresh' content='{$refresh}; url={$url}'> 
    2525        <link href="{$smarty.const.THEME}exitecms__0001.css" rel="stylesheet" type="text/css" /> 
     26        <script type='text/javascript' src='{$smarty.const.INCLUDES}jscripts/core_functions__0001.js'></script> 
    2627    </head> 
    2728    <body class='body'> 
     
    3334                            <form name='loginform1' method='post' action='{$smarty.const.BASEDIR}setuser.php?login=yes'> 
    3435                                <img src='{$smarty.const.THEME}images/{$settings.sitebanner}' alt='{$settings.sitename}' style='width:480px;margin:5px;'/> 
    35                                 {foreach from=$auth_methods item=method key=i} 
    36                                     {if $method_count > 1} 
    37                                         {if $method == "ldap"} 
    38                                             <div class='side-label'> 
    39                                                 {$locale.069} {$method|upper} {$locale.061}: 
    40                                             </div> 
    41                                             <div id='box_login{$i}' name='login{$i}' style='display:{if $auth_state.$i}block{else}none{/if};'> 
    42                                         {elseif $method == "ad"} 
    43                                             <div class='side-label'> 
    44                                                 {$locale.069} {$method|upper} {$locale.061}: 
    45                                             </div> 
    46                                             <div id='box_login{$i}' name='login{$i}' style='display:{if $auth_state.$i}block{else}none{/if};'> 
    47                                         {elseif $method == "local"} 
    48                                             <div class='side-label'> 
    49                                                 {$locale.069} {$locale.061}: 
    50                                             </div> 
    51                                             <div id='box_login{$i}' name='login{$i}' style='display:{if $auth_state.$i}block{else}none{/if};'> 
    52                                         {elseif $method == "openid"} 
    53                                             <div class='side-label'> 
    54                                                 {$locale.069} {$locale.067}: 
    55                                             </div> 
    56                                             <div id='box_login{$i}' name='login{$i}' style='display:{if $auth_state.$i}block{else}none{/if};'> 
    57                                         {/if} 
    58                                     {/if} 
    59                                     <div style='padding:5px;'> 
    60                                     {if $method == "ldap"} 
    61                                         {$locale.061}: <input type='text' name='ldap_name' class='textbox' style='width:145px' /> 
    62                                         &nbsp;&nbsp;&nbsp; 
    63                                         {$locale.062}: <input type='password' name='ldap_pass' class='textbox' style='width:145px' /><br /> 
    64                                     {elseif $method == "ad"} 
    65                                         {$locale.061}: <input type='text' name='ad_name' class='textbox' style='width:145px' /> 
    66                                         &nbsp;&nbsp;&nbsp; 
    67                                         {$locale.062}: <input type='password' name='ad_pass' class='textbox' style='width:145px' /><br /> 
    68                                     {elseif $method == "local"} 
    69                                         {$locale.061}: <input type='text' name='user_name' class='textbox' style='width:145px' /> 
    70                                         &nbsp;&nbsp;&nbsp; 
    71                                         {$locale.062}: <input type='password' name='user_pass' class='textbox' style='width:145px' /><br /> 
    72                                     {elseif $method == "openid"} 
    73                                         <input type='text' name='user_openid_url' class='textbox' style='width:128px;background: url({$smarty.const.IMAGES}openid_small_logo.gif) no-repeat; padding-left: 18px;' /> 
    74                                         &nbsp;&nbsp;&nbsp; 
    75                                         <span class='small' style='font-size:90%;'>  <a href="http://{$settings.locale_code}.wikipedia.org/wiki/OpenID"  target="_blank">{$locale.068}</a></span><br /> 
    76                                     {/if} 
    77                                     </div> 
    78                                     {if $method_count > 1} 
    79                                         </div> 
    80                                     {/if}            
     36                                {foreach from=$auth_templates item=method key=i} 
     37                                    {include file=$i} 
    8138                                {/foreach} 
    82                                     <hr /> 
    83                                     <div style='text-align:center'> 
    84                                         <input type='checkbox' name='remember_me' value='yes' title='{$locale.063}' style='vertical-align:middle;'{if $remember_me|default:"no" == "yes"} checked="checked"{/if}/> 
    85                                         <input type='submit' name='login' value='{$locale.064}' class='button' /><br /> 
    86                                         <input type='hidden' name='javascript_check' value='n' /> 
    87                                     </div> 
    88                                 </form> 
     39                                <hr /> 
     40                                <div style='text-align:center'> 
     41                                    <input type='checkbox' name='remember_me' value='yes' title='{$locale.063}' style='vertical-align:middle;'{if $remember_me|default:"no" == "yes"} checked="checked"{/if}/> 
     42                                    <input type='submit' name='login' value='{$locale.064}' class='button' /><br /> 
     43                                    <input type='hidden' name='javascript_check' value='n' /> 
     44                                </div> 
     45                            </form> 
    8946                            {literal} 
    9047                            <script type='text/javascript'> 
Note: See TracChangeset for help on using the changeset viewer.