|
Friday, 28 May 2004 |
|
Page 2 of 3 JavaScript This script needs to be put in between the <head> .... </head> element of your templates index.php file; function toggleBox(szDivID, iState) // 1 visible, 0 hidden { if(document.layers) // NN4 { document.layers[szDivID].visibility = iState ? "show" : "hide"; } else if(document.getElementById) // gecko(NN6) + IE5+ { var obj = document.getElementById(szDivID); obj.style.visibility = iState ? "visible" : "hidden"; } else if(document.all) //IE 4 { document.all[szDivID].style.visibility = iState ? "visible" : "hidden"; } } <div> Box I decided that, rather than code my own login procedure, I would place the Mambo 'inset' position into a hidden <div> box and publish the Login module into there. This allows me not to worry about the login process should it change in future versions of Mambo. This would also allow me to put other modules in there, if I wanted, by publishing the modules into the 'inset' positon. The DIV box is placed within the <body> ... </body> of your template. <div id="LoginBox"> <table> <tr> <td colspan="2"> <?php mosLoadModules( 'inset' ); ?> </td> </tr> <tr> <td width="50%"> <a xhref="administrator/index.php"> <img xsrc="images/M_images/con_info.png" width="16" height="16" border="0" /> <font size="1"><strong>Admin</strong></font> </a> </td> <td width="50%" align="right"> <a xhref="http://www.troozers.com/#" onClick="toggleBox('LoginBox',0); return false;"> <img xsrc="images/cancel_f2.png" width="20" height="20" border="0" /> </a> </td> </tr> </table> </div>
|