On the left bar of my page I have the main nav menu and below that is a javascipt section which deals with login for the members only areas. This section determines if the person is logged in from data left in the header as window variables, and responds by writing either the login form and associated links, or the persons name and associated links.
I would like my menu to scroll with the page, since some of the pages get long. This results in the menu passing over the login section, which looks really bad. What I would like to see is the login section scroll with the menu so that they move together.
Is there some way to do this?
Ed
Javascipt section attached to menu?
Hi Ed,
Use a js conditional in the main menu definition to specify the aI(). In the aI() string, you essentially include the html code that you would normally use to create the tabe/form in the text= property. You'd also set type=html or type=form as appropriate. So, try adding the following (without the lin wraps) to your main menu definition:
Before you test, remember to remove or comment out the code that you currently have in your html file that generates your table/form.
Kevin
Use a js conditional in the main menu definition to specify the aI(). In the aI() string, you essentially include the html code that you would normally use to create the tabe/form in the text= property. You'd also set type=html or type=form as appropriate. So, try adding the following (without the lin wraps) to your main menu definition:
Code: Select all
if (window.loggedIn == '1') {
aI("text=<table border='0' WIDTH='120' cellspacing='0' cellpadding='0' class='login'><tr><td><br>You are logged in as:<br>" + window.ufname + "<br>" + window.ulname + "<br><br><a href='javascript:trak(\"/register.shtml\")' class='login'>Edit my Profile</a></td></tr></table>;type=html;");
}
else {
aI("text=<form name='login' action='#' method='get'><input type='hidden' value='login' name='formuse'><table border='0' width=120 class='login'><tr><td>username:<br><input name='username' type='text' size='12' maxlength='32'></td></tr><tr><td>password:<br><input name='password' type='password' size='8' maxlength='8'> <input type='image' src='/i/go-login.gif' value='submit' ></td></tr><tr><td><a href='javascript:trak(\"/login.shtml\")' class='login'>Forgot Password?</a></td></tr><tr><td><br><a href='javascript:trak(\"/register.shtml\")' class='login'>New Brokers,<br>register here</a></td></tr></table></form>;type=form;");
}
Kevin