summaryrefslogtreecommitdiff
path: root/src/Nodes
diff options
context:
space:
mode:
authorAndres Rey <[email protected]>2018-09-01 15:59:05 +0100
committerAndres Rey <[email protected]>2018-09-01 15:59:05 +0100
commitf1d5cd1c3ad2a34ef770a64eab99ace2c4c923d1 (patch)
tree943ead0ceadedcc037b119f67c231f14a3170181 /src/Nodes
parentf34b06491f08db540a355526d790a45bbc4688b7 (diff)
Add unlikely candidate
Diffstat (limited to 'src/Nodes')
-rw-r--r--src/Nodes/NodeUtility.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Nodes/NodeUtility.php b/src/Nodes/NodeUtility.php
index 752e9f4..bb63828 100644
--- a/src/Nodes/NodeUtility.php
+++ b/src/Nodes/NodeUtility.php
@@ -17,13 +17,13 @@ class NodeUtility
* @var array
*/
public static $regexps = [
- 'unlikelyCandidates' => '/banner|breadcrumbs|combx|comment|community|cover-wrap|disqus|extra|foot|header|legends|menu|related|remark|replies|rss|shoutbox|sidebar|skyscraper|social|sponsor|supplemental|ad-break|agegate|pagination|pager|popup|yom-remote/i',
+ 'unlikelyCandidates' => '/-ad-|banner|breadcrumbs|combx|comment|community|cover-wrap|disqus|extra|foot|header|legends|menu|related|remark|replies|rss|shoutbox|sidebar|skyscraper|social|sponsor|supplemental|ad-break|agegate|pagination|pager|popup|yom-remote/i',
'okMaybeItsACandidate' => '/and|article|body|column|main|shadow/i',
'extraneous' => '/print|archive|comment|discuss|e[\-]?mail|share|reply|all|login|sign|single|utility/i',
'byline' => '/byline|author|dateline|writtenby|p-author/i',
'replaceFonts' => '/<(\/?)font[^>]*>/gi',
'normalize' => '/\s{2,}/',
- 'videos' => '/\/\/(www\.)?(dailymotion|youtube|youtube-nocookie|player\.vimeo)\.com/i',
+ 'videos' => '/\/\/(www\.)?((dailymotion|youtube|youtube-nocookie|player\.vimeo|v\.qq)\.com|(archive|upload\.wikimedia)\.org|player\.twitch\.tv)/i',
'nextLink' => '/(next|weiter|continue|>([^\|]|$)|»([^\|]|$))/i',
'prevLink' => '/(prev|earl|old|new|<|«)/i',
'whitespace' => '/^\s*$/',