Click here to Skip to main content
15,894,825 members
Please Sign up or sign in to vote.
1.00/5 (4 votes)
See more:
hello all,
Can anyone show how to translate a language from english to german by clicking germen in the dropdown lists....
pls show how it works for a simple login page.....


.html file:
JavaScript
<!doctype html>
<html>
<script type="text/javascript" src="e.js"></script>
<div id="logform">
	<form>
		<dl> <dt><label id="username">Login</label>
			<input type="text"  name="loginName" value=""></dt>
		<dt><label>Password</label>
		<input type="password" id="password" name="loginPass" value=""></dt>
		<dt><select ><option>English</option>
		<option  önClick="tran();">German</option>
		</select></dt></dl>
	</form>
</div>
</html>


.js file:
function tran(){
var str=document.getElementById("logform").innerHTML; 
var n=str.replace("Password","Kennwort");
document.getElementById("password").innerHTML=n;
}

i done only for changing password.... but its not working.... can anyone help me
Posted
Updated 25-Sep-12 2:18am
v4
Comments
Legor 25-Sep-12 7:58am    
It's called German. If you yourself doesnt even know how the language is called your trying to translate to ... do you really think you can write a program which can do this?
GowthamVenkatesan 25-Sep-12 8:16am    
sorry... typed by mistake

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900