Home >Web Front-end >HTML Tutorial >Detailed explanation of disabled uninputable values ​​cannot be passed to the action layer

Detailed explanation of disabled uninputable values ​​cannot be passed to the action layer

高洛峰
高洛峰Original
2017-03-06 15:05:581342browse

Let the form be in a non-inputable state. The action in the background cannot get the value. Replace disabled with readonly. After the replacement is completed, the value can be passed to the background. If I want to make the form uninputable, I set the form to:

The code is as follows:

style="cursor:not-allowed;" disabled


But after setting it up like this, I found that there is no way to get the action in the background. to the value. Finally, I searched on the Internet and found that replacing disabled with readonly. After the replacement is completed, the value can indeed be passed to the background, but the form can gain focus. Gaining focus is uncomfortable to watch. But the project is tight, so I’ll leave it at that.

After the form is set to disabled, the value cannot be passed to the background.

For more disabled and uninputable values, the value cannot be passed to the action layer for detailed explanation. Please pay attention to the PHP Chinese website for related articles!

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