| Hello, Just installed version 1.4 of the Login Form (Joomla-SMF) module and discovered that tthe table structure displayed when a user is not logged in is wrong. Look for this <<<<<<< sign in the code excerpts below and read comments. Code: echo ' <table cellspacing="0" cellpadding="0" width="100%" border="0">'; <<<<<<< A new Table is created here... if ($context['user']['is_logged']) { ... Loads of code ... else { echo $smf_pre_text, ' ', $txt[28], $smf_post_text, '<br /> <<<<<< but no ROW + CELL are created here!! <form action="index.php" name="login" method="post"> <span class="small">',$txt[35],':</span><br/> <input type="text" name="username" size="12" class="inputbox" /><br /> <span class="small">',$txt[36],':</span><br/> <input type="password" name="passwd" size="12" class="inputbox" /><br /> <input type="checkbox" name="remember" class="inputbox" value="yes" alt="',_REMEMBER_ME,'" /> <span class="small">',_REMEMBER_ME,'</span><br /> <input type="submit" value="', $txt[34], '" class="button"/><br /> <input type="hidden" name="option" value="login" /> <input type="hidden" name="lang" value="',$mosConfig_lang,'" /> <input type="hidden" name="message" value="',$message_login,'" /> </form> </td></tr> <<<<< but the ROW + CELL is closed here!!! solution - at line 223 replace: Code: else { echo $smf_pre_text, ' ', $txt[28], $smf_post_text, '<br /> by Code: else { echo '<tr><td valign="top" class="', (($moduleclass_sfx) ? 'smalltext'.$moduleclass_sfx : 'smalltext' ),'">', $smf_pre_text, ' ', $txt[28], $smf_post_text, '<br /> I took the freedom to also add the suffix option to the class of the TD to allow for some dedicated style to the "Welcome Guest" message. To stay consistent I also added the suffix to the "Welcome UserX" when a user is logged-in. find this (around line 92): Code: echo ' <tr> <td valign="top" class="smalltext">'; if ($context['in_maintenance'] && $context['user']['is_admin']) { and replace it by: Code: echo ' <tr> <td valign="top" class="', (($moduleclass_sfx) ? 'smalltext'.$moduleclass_sfx : 'smalltext' ),'">'; if ($context['in_maintenance'] && $context['user']['is_admin']) { Hope this helps ![]() |
Forum 





Author





Logged





