input {
/* 取消input默认轮廓线 */
outline: none;
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>防止用户拖拽文本域</title>
<style>
textarea {
outline: none;/* 消除outline轮廓线 */
resize: none;/* 防止用户拖拽文本域 */
}
</style>
</head>
<body>
<textarea name="" id="" cols="30" rows="10"></textarea>
</body>
</html>
学习细碎知识点记录......