解决点击输入框调起键盘时,输入框被键盘遮挡的问题

<input onfocus='foucs" />

  

function foucs(){
var client_y = document.body.clientHeight;//
 parent.scroll(0,clinet_y/2);把页面向上滚动半个页面的距离
}

  

Solve problems in the most elegant way
原文地址:https://www.cnblogs.com/yanghmartin/p/scrollup.html