HTML5 will disable the copy (solution) for Long-pressed mobile phone pages. html5 Solution
Solution:
Directly Add the following code to the CSS file to disable copy and paste on the mobile phone:
*{
-Webkit-touch-callout: none;/* the default menu of the system is disabled */
-Webkit-user-select: none;/* webkit browser */
-Khtml-user-select: none;/* early browsers */
-Moz-user-select: none;/* Firefox */
-Ms-user-select: none;/* IE10 */
User-select: none;
}
After this code is added, there will be a problem on IOS. At this time, you will find that the input box cannot be entered. This is because-webkit-user-select: none; caused by this attribute.
To solve this problem, set the attribute of input in the css file as follows:
Input {
-Webkit-user-select: auto;/* webkit browser */
}
In this way, you can learn from each other and make progress on each other!