Jump to content

Disabling TextField!!


rn14

Recommended Posts

Im attempting to disable the text field amount. The value is passed from a form on a previous page. I need to the field to be disabled when the form is opened.

Any suggestions??

 

<html>
<head>
<script type="text/javascript">
function disableField()
  {
  document.getElementById("amount").disabled=true
  }
</script>
</head>
<body><form>
<input type="text" id="amount" value="<?echo $amount;?>" />
value="Disable text field" />
</form></body>
</html> 


Link to comment
https://forums.phpfreaks.com/topic/38510-disabling-textfield/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.