News:

Want to get involved in developing SMF? Why not lend a hand on our GitHub!

Main Menu

Hi all, need a little help with the the out put of SSI login

Started by lyndonis, September 30, 2008, 11:32:41 PM

Previous topic - Next topic

lyndonis

Hi

I am using the SSI_login('url') on my site, the think is that the way it out puts the form is not right for my site.

it out puts it like this (BTW is output/out put  1 word or 2) lol

Username: !!!!!!!!!!!!!!!!!!!!!!!!!!!
Password:  !!!!!!!!!!!!!!!!!!!!!!!!!!!
                         [ Login ]

the way I would like it is

Username: !!!!!!!!!!!!!!!!!!!!!!!!!!!       Password:  !!!!!!!!!!!!!!!!!!!!!!!!!!!        [ Login ]

Thanks

Nathaniel

The easiest way to do this, would be to totally ignore the 'ssi_login()' function (because you need to reformat the html code anyway) and write your own simple login box.

Here is the PHP code that you will need to use (for SMF 1.1.x):
<?php
require_once(
'SSI.php');

// Set the redirection url.
$_SESSION['login_url'] = 'url';

// Is this personal a guest?
if($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>&nbsp;</td>
<td><input type="text" id="user" name="user" size="9" value="'
, $user_info['username'], '" /></td>
<td align="right"><label for="passwrd">'
, $txt[36], ':</label>&nbsp;</td>
<td><input type="password" name="passwrd" id="passwrd" size="9" /></td>
<td><input type="hidden" name="cookielength" value="-1" /></td>
<td><input type="submit" value="'
, $txt[34], '" /></td>
</tr>
</table>
</form>'
;
}
?>


You can edit the html code as necessary, so that its formatted correctly. ;)
SMF Friend (Former Support Specialist) | SimplePortal Developer
My SMF Mods | SimplePortal

"Quis custodiet ipsos custodes?" - Who will Guard the Guards?

Please don't send me ANY support related PMs. I will just delete them.


Advertisement: