nieuws: consistent url input to article parser
[minimedit.git] / nieuws.inc.php
index 8af5694a62dfb5e2c12987d57561e8921c9891a5..3f3f16391f6bf6c0bc8cc5276b558a697dbf6abc 100644 (file)
@@ -25,7 +25,7 @@ function shownewsarticle($url, $link = TRUE, $title = NULL)
        $title = sprintf(
                $link ? '<h3><a href="/%2$s">%s</a></h3>' : '<h2>%s</h2>',
                getoutput([1 => ' <small class="date">'.$date.'</small>']),
-               preg_replace('/\.html$/', '', $url)
+               $url
        );
        return preg_replace('{<h2>(.*?)</h2>}', $title, $html);
 }
@@ -37,7 +37,7 @@ function shownews($input, $limit = 1000)
                print "<article>";
                ob_start();
                include $url;
-               print shownewsarticle($url);
+               print shownewsarticle(preg_replace('/\.html$/', '', $url));
                print "</article>\n\n";
 
                if (--$limit <= 0) break;