Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

splash screen help

Options
  • 07-07-2006 8:15am
    #1
    Closed Accounts Posts: 238 ✭✭


    hi guys. im developing a hotspot for a client and am having some trouble with a script for login.
    <html>
    <head><title>Welcome to whatever</title></head>
    <body bgcolor=#ffcc00 text=000000>
    		<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
    			<tr align="center">
    				<td><img src="images/whatever.gif" alt="" width="231" height="50" border="0"></td>
    			</tr>
    			<tr>
    				<td align="center">
    					<form method="POST" action="$action?redirect=$redirect">
    						<table border=0 cellpadding=5 cellspacing=0>
    							<tr>
    								<td colspan="2">Welcome to whatever.</td>
    							</tr>
    							<tr>
    								<td align=left height="23">Login: </td>
    								<td align=left height="23"><input type="text" name="user"></td>
    							</tr>
    							<tr>
    								<td align=left height="23">Password: </td>
    								<td align=left height="23"><input type="password" name="pass"></td>
    							</tr>
    							<tr>
    								<td colspan="2" align=right height="23"><input type="image" name="mode_login" src="images/login.gif" width="55" height="17" border="0"></td>
    							</tr>
    						</table>
    						<input type="hidden" name="redirect" value="$redirect">
    					</form>
    				</td>
    			</tr>
    			<tr>
    				<td></td>
    			</tr>
    		</table>
    		<p>
    		<p>
    
    this is the script. i need the user of this script to only have to type in their name, not the domain. ie the user would type 'johndoe' and the page will complete @mydomain.com how do i do this? i am experimenting with this javascript
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Untitled Document</title>
    <script type="text/javascript"> 
    function append(formName) {
    var domain = "whatever.com"; 
    var user = document.forms[formName].user.value; 
    var parts = user.split("@");
    if (parts[1] != domain) {
    document.forms[formName].user.value += "@" + domain; 
    }
    document.forms[formName].submit();
    }
    </script>
    
    <form name="login"> 
    <input name="user"><input type="button" value="Submit" onClick="append('login')">
    </form>
    
    </head>
    
    <body>
    </body>
    </html>
    

    but how do i integrate the two?
    i dont know where to put this action="$action?redirect=$redirect"> from the first code, into my javascript

    any help much appreciated:confused:


Comments

  • Closed Accounts Posts: 4,655 ✭✭✭Ph3n0m


    where exactly is the redirection meant to be going?


  • Closed Accounts Posts: 238 ✭✭7aken


    that im not to sure of. its an internal program written by another company and is not directly editable. the only support they can give us is that this action="$action?redirect=$redirect"> is the re-direct. it goes to 'x' location and gets authenticated (form is username and password)... i know its vague but this is what im working with... anyone got any ideas???


  • Closed Accounts Posts: 4,655 ✭✭✭Ph3n0m


    7aken wrote:
    that im not to sure of. its an internal program written by another company and is not directly editable. the only support they can give us is that this action="$action?redirect=$redirect"> is the re-direct. it goes to 'x' location and gets authenticated (form is username and password)... i know its vague but this is what im working with... anyone got any ideas???


    Have to say that is the crappiest support I have ever seen.

    Problem is a form action needs values - for example $action - where is it to get the value for this? As the form needs that information to pass on

    Basically your form is looking for several things

    $action?redirect=$redirect

    $action - this is a value that needs to be password on - could be a page, could be a number - does anyone there know

    $redirect - again this value needs to be created

    You really need to find out where and how these values are being created


  • Closed Accounts Posts: 238 ✭✭7aken


    its a closed proprietary system. i was just hoping someone might know a way around. thanks for having a look.


Advertisement