diff --git a/api.php b/api.php index 6e86e28..752eba0 100644 --- a/api.php +++ b/api.php @@ -153,26 +153,110 @@ function fetchFromGoUpc($ean) { return $empty; } -// ── NOUVELLE FONCTION : SCRAPPING UPCINDEX.COM (MODIFIÉE AVEC MÉTADONNÉES) ── +// ── FONCTION : SCRAPPING UPCINDEX.COM (CORRIGÉE) ── function fetchFromUpcIndex($ean) { $empty = emptyPhysicalResult(); $url = "https://www.upcindex.com/" . urlencode($ean); $html = httpGet($url, 15); if (!$html) return $empty; - // Recherche du titre - if (preg_match('/