mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2024-11-26 19:36:52 +03:00
Avoid bot exclusion.
This commit is contained in:
parent
be3620acb7
commit
9fc1e97efe
1 changed files with 8 additions and 1 deletions
|
@ -161,7 +161,14 @@ class LeBonCoinBridge extends BridgeAbstract {
|
|||
);
|
||||
|
||||
$url = self::URI . 'recherche/?' . http_build_query($params);
|
||||
$html = getContents($url)
|
||||
|
||||
$header = array(
|
||||
'Accept: text/html',
|
||||
'Accept-Language: ' . getEnv('HTTP_ACCEPT_LANGUAGE'),
|
||||
'Accept-Encoding: identity'
|
||||
);
|
||||
|
||||
$html = getContents($url, $header)
|
||||
or returnServerError('Could not request LeBonCoin. Tried: ' . $url);
|
||||
|
||||
if(!preg_match('/^<script>window.FLUX_STATE[^\r\n]*/m', $html, $matches)) {
|
||||
|
|
Loading…
Reference in a new issue