1
0
mirror of https://github.com/RSS-Bridge/rss-bridge.git synced 2025-01-17 14:18:35 +01:00

[SensCritique] Fix bridge (#3860)

This commit is contained in:
Damien Calesse 2023-12-27 13:17:49 +01:00 committed by GitHub
parent ad2d4c7b1b
commit c8178e1fc4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,7 +57,7 @@ class SensCritiqueBridge extends BridgeAbstract
} }
$html = getSimpleHTMLDOM($uri); $html = getSimpleHTMLDOM($uri);
// This selector name looks like it's automatically generated // This selector name looks like it's automatically generated
$list = $html->find('div.Universes__WrapperProducts-sc-1qa2w66-0.eVdcAv', 0); $list = $html->find('div[data-testid="row"]', 0);
$this->extractDataFromList($list); $this->extractDataFromList($list);
} }
@ -69,6 +69,7 @@ class SensCritiqueBridge extends BridgeAbstract
if ($list === null) { if ($list === null) {
returnClientError('Cannot extract data from list'); returnClientError('Cannot extract data from list');
} }
foreach ($list->find('div[data-testid="product-list-item"]') as $movie) { foreach ($list->find('div[data-testid="product-list-item"]') as $movie) {
$item = []; $item = [];
$item['title'] = $movie->find('h2 a', 0)->plaintext; $item['title'] = $movie->find('h2 a', 0)->plaintext;