0

I am facing exactly this issue only difference is my scrolls down not top.

I try the workaround but can't get what changes I need to do. Can someone please guide me?

https://success.salesforce.com/issues_view?id=a1p30000000T2oLAAS

3

This hack worked well for me. Add the following JavaScript to your page:

<script> 
var ua=navigator.userAgent; 
if((ua.indexOf('Salesforce')!=-1)&&(ua.indexOf('iPhone')!=-1||ua.indexOf('iPad')!=-1)&&(ua.indexOf('OS/8')!=-1||ua.indexOf('OS 8')!=-1)&&(ua.indexOf('Safari')==-1)){ 
function IOS_SCROLL_BOOTSTRAP() { 
var children = Array.prototype.slice.call(document.body.children), 
placeholder = document.createElement('section'), 
fragment = document.createDocumentFragment(), 
styles, 
width, 
height; 
children.forEach(function(c){fragment.appendChild(c);}); 
placeholder.appendChild(fragment); 
styles = [ 
'width:100%;', 
'height:', (window.screen.height - 42), 'px;', 
'position: absolute; overflow: auto; -webkit-overflow-scrolling: touch' 
].join(''); 
placeholder.style.cssText = styles; 
document.body.appendChild(placeholder); 
} 
window.addEventListener('load', function (e) { 
IOS_SCROLL_BOOTSTRAP(); 
}); 
} 
</script>

If it did not work for you, it will be helpful to know what device, OS version and Safari version are you facing this issue on.

  • Not working for me. Shall I provide you my code? – Testing_SFDC Apr 14 '17 at 11:54
  • Also where should I place this code? Just at the begining of the page? – Testing_SFDC Apr 14 '17 at 11:54
  • Mine it's 10.2.1 – Testing_SFDC Apr 14 '17 at 12:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.