5 <meta name=
"viewport" content=
"width=device-width, initial-scale=1" />
7 <link rel=
"stylesheet" href=
"../style.css#" type=
"text/css" />
8 <title>AD blocking
</title>
9 <script type=
"text/javascript">
11 let href
= location
.href
;
12 for(let i
=href
.length
-1;i
>0;i
--){
13 if('/'==href
.charAt(i
) && '/'==href
.charAt(i
-3))
20 location
.href
= location
.href
.substring(0,i
+1)+page
;
22 function nav2Lang(lang
){
24 let href
= location
.href
;
25 location
.href
= location
.href
.substring(0,i
-2)+lang
+location
.href
.substring(i
);
30 <header class='header'
>
31 <a class=
"logo" href=
"javascript:void(0)" onclick=
"return nav2('index.html#')">Home
</a> <a class=
"logo" href=
"javascript:void(0)" onclick=
"return nav2('tags/index.html#')">Tags
</a>
34 <a class=
"logo" href=
"javascript:void(0)" onclick=
"return nav2Lang('zh')">简体中文
</a>
42 <div class=
"container">
43 <h1 class=
"title">AD blocking
45 <span class=
"subtitle"></span>
52 <p><a href=
"../adblock_domain/index.html">Host blocking
</a>。
</p>
54 <li>Use
<a href=
"../bookmarklet/index.html">bookmarklet
"list all script urls
"</a> to generate url links, long pressing dubious script (usually
3rd-party library) link, click
"Block domain root
".
</li>
58 <p><a href=
"../sitejs/index.html">Javascript and CSS for domains
</a>。
</p>
60 <li>Long press the button
"js
", click the menu
"MarkAD mode
". In
"markAD mode
", click page element to show all attributes and generate CSS AD blocking styles. By default,
"display:none
" is used. If
"display
" appears in the attribute information, recommend to use
"transform:scale(
0)!important
" instead.
</li>
64 <p>Long press the tab manager button, check
"Videos only
" for video sites and
"Images only
" for image sites. Other AD blocking options are
"Hide pseudo elements
" and
"Hide iframes
".
</p>
66 <li>Add prefix
"i:
0mc32:
" to url when bookmarking, then the option
"Images only
" applies to whole url subtree. Similarly,
"c16
" for the option
"Videos only
" and
"c12
" for hiding both pseudo elements and iframes.
</li>
67 <li>Long press the button [☰], check the option
"Fullscreen autoplay
". Videos are autoplayed in fullscreen mode, ADs have no chance to appear.
</li>
71 <p>Long press the setting button, check the option
"Block external scripts
".
<a href=
"i:61:../searchurl/func.html">UI
</a> website has option to also block dubious
3rd party resources.
<a href=
"file:///data/data/info.torapp.uweb/files/js.allow">js.allow
</a> whitelists js libraries.
</p>
74 <p>Long press the button [☰],
"Disable floating ADs
",
"Disable banners
",
"clear all timers
",
"stop events
" and
"Sleep ...
" are also available.
</p>
77 <p>Click the button with image icon to hide all images.
</p>
80 <p>Click the button
"JS
" to disable javascript.
</p>
83 <p><a href=
"file:///data/data/info.torapp.uweb/files/url.deny">url.deny
</a>: one giant regular expression for blocked urls (java grammar), in which carriage returns (CR or newline) are ignored and
"#
" is for comments.
</p>
88 <p>Last Modified:
2 April
2024<br>
89 add js function in README
<br>
94 src='https://giscus.app/client.js'
95 data-repo=
"torappinfo/uweb"
96 data-repo-id=
"MDEwOlJlcG9zaXRvcnkzMDIyMDU3MjE="
97 data-category=
"Announcements"
98 data-category-id=
"DIC_kwDOEgNLGc4CQjsh"
101 data-reactions-enabled=
"1"
102 data-emit-metadata=
"0"
103 data-input-position=
"top"
107 crossorigin=
"anonymous" async
>