// Otherwise they're a guest - this time ask them to either register or login - lazy bums...
elseif (!empty($context['show_login_bar']))
{
echo '
<script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/sha1.js"></script>
<form id="guest_form" action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" ', empty($context['disable_login_hashing']) ? ' onsubmit="hashLoginPassword(this, \'' . $context['session_id'] . '\');"' : '', '>
<label for="user">
', $txt['username'], '
<input type="text" id="user" name="user" size="10" class="input_text" />
</label>
<label for="passwrd">
', $txt['password'], '
<input type="password" id="passwrd" name="passwrd" size="10" class="input_password" />
</label>';
/*
<label for="cookielength">
', $txt['cookielength'], '
<select id="cookielength" name="cookielength">
<option value="60">', $txt['one_hour'], '</option>
<option value="1440">', $txt['one_day'], '</option>
<option value="10080">', $txt['one_week'], '</option>
<option value="43200">', $txt['one_month'], '</option>
<option value="-1" selected="selected">', $txt['forever'], '</option>
</select>
</label>
*/
echo '
<input type="hidden" id="cookielength" name="cookielength" value="-1" />
<input type="submit" value="', $txt['login'], '" class="button_submit" /><br />
<div class="info">', $txt['welcome_guest'], '</div>';
if (!empty($modSettings['enableOpenID']))
echo '
<label for="openid_url">
', $txt['openid'], '
<input type="text" name="openid_identifier" id="openid_url" size="19" class="input_text openid_login" />
</label>';
echo '
<input type="hidden" name="hash_passwrd" value="" /><input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
</form>';
}
ETA: Test edit.