Page MenuHomeDevCentral

D724.id1817.diff
No OneTemporary

D724.id1817.diff

diff --git a/page.php b/page.php
--- a/page.php
+++ b/page.php
@@ -89,6 +89,11 @@
public $skipAuthor;
/**
+ * @var bool If true, this site uses an anti ad blocker technology to force users to show ads
+ */
+ public $antiAdBlocker = true;
+
+ /**
* @var mixed If not null, contains an array for another service to use
*/
public $switchTo = null;
diff --git a/templates/wikipedia-fr/Lien_web.php b/templates/wikipedia-fr/Lien_web.php
--- a/templates/wikipedia-fr/Lien_web.php
+++ b/templates/wikipedia-fr/Lien_web.php
@@ -48,6 +48,7 @@
$template->pageDate = $page->date;
$template->skipYMD = $page->skipYMD;
$template->skipMD = $page->skipMD;
+ $template->antiAdBlocker = $page->antiAdBlocker;
return $template;
}
@@ -99,6 +100,12 @@
$this->params['site'] = $this->site;
$this->params['consulté le'] = $this->accessdate;
- return parent::__toString();
+ $template = parent::__toString();
+
+ if ($this->antiAdBlocker) {
+ $template .= " {{Publicité forcée}}";
+ }
+
+ return $template;
}
}

File Metadata

Mime Type
text/plain
Expires
Mon, Nov 18, 22:41 (22 h, 13 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2251185
Default Alt Text
D724.id1817.diff (1 KB)

Event Timeline