How to thwart a Safari 5 reader
The Safari 5 reader shows the pages of the site without ads, apparently a way to attack Google, whose Adsense service monetizes most websites.

This is against the rules of the site, as the terms of use prohibit changing pages before viewing any tool.
So webmasters need to find a way to ditch the tool to preserve their ad revenue.
Apple did not implement the tool itself, it simply integrated Readability open source software.
By the way, the Readability team initially praised Apple for its product before realizing that it was using its own code.
It can be seen that we are between intellectuals!
Test pages
To check the effectiveness of the webmaster's actions to counter this player, here is a list of pages on this site where the player button does not appear in the Safari browser.
Thus, it will be possible to check in time whether this is always the case with the following versions of Safari.
- Web 2.0.
- CMS list.
- Which CMS to choose.
- FAQ.
- Blurred contour using GIMP.
- All GIMP tutorials on this site eliminate the reader.
- Diagnosis of SEO.
Giant shape, but with important text.
How to remove a drive
We will try to learn from the test pages.
However, as you can see, it is not easy to understand why the player button appears or not. But there are times when he always appears .
A page with a simple text frame always displays the player. When you add tables, images, lists, this becomes less obvious.
The title of the text is something that seems to contradict the script in Safari: it is difficult for him in this case to form a page containing plain text, which is his other goal along with the goal of disturbing Google and all its affiliates .
On this page, I included the next paragraph in <div>, and that was enough to turn off the player.
Use JavaScript
The following code is used to identify the Safari browser:
var agent = navigator.userAgent; var isSafari = agent.indexOf("Safari") > -1 && agent.indexOf("Chrome") == -1;
Load the page with this command:
window.location.reload()
However, the Safari reader builds an abbreviated page based on the rendering done by the browser and after executing JavaScript code, it is also impossible to check the state of the page using JavaScript .
Instead, JavaScript will be used to prevent readability from working with features that only work with Safari, as recognized above.
Sample code:
<script type="text/javascript">
var agent = navigator.userAgent;
var isSafari = agent.indexOf("Safari") > -1 && agent.indexOf("Chrome") == -1;
function reloading() { window.location.reload(); }
window.onblur=function()
{
if(isSafari) {
setTimeout(reloading, 6000);
}
}
</script>
This code loads the page after six seconds when you go under the player and reassigns the initial full page.
But it prevents you from using the URL bar .
And it can't be used with pages displaying paid ads by number of impressions.
Use only if the number of Safari users is very large.
Demo.
If tools like the Safari reader spread, we should also see the spread of dynamic pages dependent on JavaScript code, rather than text pages easily interpreted by these tools.