Responsive layout screen can be drag off the screen in preview


#1

I did a responsive mobile app prototype and when I preview it on the web browser (used Chorome inspect to change to various phone size )the whole screen became draggable, which means I can literary drag my app page off the intractable “phone” area. Do you guys know how to prevent that happening?

Thank you!!!


(Freelancer) #2

try this code in the HEADER html

	<script type="text/javascript">
	document.ontouchmove = function(e){ e.preventDefault()}; 
	</script>

#3
<head>
Above is my header code. where would be better to add the code in? Sorry I do not have any coding experience.

Thank you!!!


(Freelancer) #4

before the </head>


#5

The code is not working T_T