From 3ac143efbed6d43cd58e08a68391ab2c37f1a858 Mon Sep 17 00:00:00 2001 From: Oros Date: Thu, 14 Feb 2013 23:21:48 +0100 Subject: [PATCH] Fix bug modified: autoblog.php --- 0.3/autoblog.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/0.3/autoblog.php b/0.3/autoblog.php index edcae2d..255fe81 100755 --- a/0.3/autoblog.php +++ b/0.3/autoblog.php @@ -490,7 +490,11 @@ class VroumVroum_Blog $extensions = implode('|', $extensions); $from = parse_url($url); - $from['path'] = preg_replace('![^/]*$!', '', $from['path']); + if( isset($from['path']) ) { // not exist if http://exemple.com + $from['path'] = preg_replace('![^/]*$!', '', $from['path']); + }else{ + $from['path'] = ''; + } preg_match_all('!(src|href)\s*=\s*[\'"]?([^"\'<>\s]+\.(?:'.$extensions.'))[\'"]?!i', $content, $match, PREG_SET_ORDER);