Home  >  Article  >  Web Front-end  >  Set input to read-only effect through disabled and readonly_HTML/Xhtml_Web page production

Set input to read-only effect through disabled and readonly_HTML/Xhtml_Web page production

WBOY
WBOYOriginal
2016-05-16 16:38:061792browse

There are two ways to achieve the read-only effect of input: disabled and readonly.

Of course the two effects can only be read but not edited, but they are very different.

Disabled indicates that the input is invalid and its value will not be passed to any program, such as asp, php, etc.
Readonly only cannot be edited and does not affect the transfer of its value.

Disabled use:
Readonly use:

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn