From 205aa25e9b395a47b2995011739307070f1090c9 Mon Sep 17 00:00:00 2001 From: Steven Wittens Date: Tue, 30 Dec 2003 06:28:01 +0000 Subject: - Improved regexp for encoding extraction --- modules/aggregator/aggregator.module | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/aggregator/aggregator.module') diff --git a/modules/aggregator/aggregator.module b/modules/aggregator/aggregator.module index c9833e5fd..0dbde5585 100644 --- a/modules/aggregator/aggregator.module +++ b/modules/aggregator/aggregator.module @@ -326,7 +326,7 @@ function import_refresh($feed) { } // extract the XML file's encoding (the XML parser in PHP4 doesn't do this by itself): - if (ereg('^[^>]+encoding="([^"]+)"', $data, $match)) { + if (ereg('^<\?xml[^>]+encoding="([^"]+)"', $data, $match)) { $encoding = $match[1]; } -- cgit v1.2.3