How to disable input in HTML

the first method:

Add the readonly= "readonly" attribute to the input element

1 <input type="text" readonly="readonly" />

The second method:

Add disabled= "disabled" attribute to the input element

1 <input type="text" disabled="disabled" />

The third high-energy method:

If these two methods can't be solved, and you can't return the plug-in, there is another black technology (mentally retarded method) you can try:

Just get a mask layer, block the input box, and block it perfectly. . . It's rather sloppy, use it with caution!

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324837030&siteId=291194637