一般我们都是使用html meta头来禁止网页进行缩放操作<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no">但是在ios设备上面这条meta是完全不起作用的这个时候我们可以使用js来禁止缩放事件document.documentElement.addEventListener('touchstart', function (event) { if (event.touches.length > 1) { event.preventDefault(); } }, false); var lastTouchEnd = 0; document.documentElement.addEventListener('touchend', function (event) { var now = Date.now(
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> <style> [contenteditable]:focus{outline: none;} .QiunsEditor{ width:800px; height:400px; border:1px so
SK
Devil in My Mind.