Sometimes it is very simple things, because some of their own carelessness, may be in that circle has been around for a long time to go round.
So I would like to write these very simple stupidity, with June share ~
First of all, you know that <input> has a type named "button", which is visible or not determined by the "disabled" attribute.
The following code, I originally intended to be an input box and three buttons. Before clicking the "Edit" button, the other three are "not available" status, click on the back to be usable.
"Content-type"Content="text/html; Charset=utf-8"><title>insert title Here</title><script type="Text/javascript">function edit () {document.getElementById ("Editcode"). Disabled =true; document.getElementById ("Invitecode"). Disabled =false; document.getElementById ("Randomcode"). Disabled =false; document.getElementById ("Submitcode"). Disabled =false; }</script>"Ten"> <tr> <th> Current invitation code:</th> <td><input type="text"Name="Invitecode"Id="Invitecode"Value="" class="input"Size="6"Disabled/></td> <td><input type="Button"Name="Randomcode"Id="Randomcode"Value="Random Access"disabled/></td> </tr> <tr align=" Right"> <td><input type="Button"Name="Editcode"Id="Editcode"Value="Edit"onclick="edit ()"/></td> <td><input type="Submit"Name="Submitcode"Id="Submitcode"Value="Determine"disabled/></td> </tr> </table> </s:form></body>It is simple to set the disabled type of each element to be available or unavailable in the edit () function.
I met a big problem in the middle that I always thought I was looking for the solution is not available, that is, I named the element "edit", "submit" and so on, may have some content with itself conflict. Error after reviewing element: object is not a function.
After renaming everything to be resolved.
JS Implementation input button is never available to become available