Código PHP:
function ssi_login($redirect_to = 'DIRECCION DE LA PAGINA RESTRINGIDA', $output_method = 'echo')
{
global $scripturl, $txt, $user_info, $context;
if ($redirect_to != '')
$_SESSION['login_url'] = $redirect_to;
if ($output_method != 'echo' || !$user_info['is_guest'])
return $user_info['is_guest'];
echo '
<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '">
<table border="0" cellspacing="1" cellpadding="0" class="ssi_table">
<tr>
<td align="right"><label for="user">', $txt[35], ':</label> </td>
<td><input type="text" id="user" name="user" size="9" value="', $user_info['username'], '" /></td>
</tr><tr>
<td align="right"><label for="passwrd">', $txt[36], ':</label> </td>
<td><input type="password" name="passwrd" id="passwrd" size="9" /></td>
</tr><tr>
<td><input type="hidden" name="cookielength" value="-1" /></td>
<td><input type="submit" value="', $txt[34], '" /></td>
</tr>
</table>
</form>';