Hiding Address Bar in Mobile Safari With Reader Button Visible

强颜欢笑 提交于 2019-12-04 12:49:11

I've looked around quite a bit and there doesn't appear to be any way to disable the reader button. The only possible solution I found was to make your site less "readable" so Safari doesn't add the reader button. Exactly what makes a site "readable" is pretty murky.

Here's some research on what makes something "readable": http://mathiasbynens.be/notes/safari-reader

Here's a method to make it less readable by putting your content in CSS: http://askmike.org/2012/12/a-hacky-way-to-remove-the-reader-button-in-ios-safari/

The bottom line seems to be that there is no solution. Hopefully Apple will add a meta tag to disable it or at least let us hide the address bar faster.

Here is what worked for me:

I placed all content inside an ol tag.

<ol style = "padding:0;margin:0"> 
   my content
</ol>

From what I read elsewhere, the reader is partly triggered by the number of words on a page, but does not count words inside an ol.

duhoang

You can disable the reader button by hiding the content that triggers it.

And then displaying that content 1s after the page loads.

For instance, hide all your <p> elements if they are triggering the reader button.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!