पर समान प्रश्नों के उत्तर पर ध्यान दिया है, लेकिन मेरे जीवन के लिए, मैं यह नहीं समझ सकता कि मैं क्या गलत कर रहा हूं।एक टेक्स्ट बॉक्स का मान अन्य
मेरे पास दो टेक्स्ट बॉक्स और एक बटन है। पाठ पहला पाठ बॉक्स में जोड़ा जाता है और बटन दबाया है, मैं दूसरे पाठ बॉक्स के लिए पहला पाठ बॉक्स के मूल्य/पाठ लागू करना चाहते हैं:
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script>
$("#button").click(function() {
var contents = $("#textbox").val();
$("#container").val(contents);
});
</script>
</head>
<body>
<input type="text" id="textbox" /> <input type="submit" id="button" value="Press This" />
<br />
<input type="text" id="container" />
</body>
</html>