load autoblog.php from relative parent dir instead of full

( PHP Fatal error:  require_once(): Failed opening required '/autoblog.suumitsu.eu/htdocs/autoblog.php')
This commit is contained in:
Mitsukarenai 2013-04-08 13:59:49 +02:00
parent df3fa09d4b
commit 0d7c60b54b

View file

@ -81,7 +81,7 @@ function createAutoblog($type, $sitename, $siteurl, $rssurl, $error = array()) {
$rss->addNewAutoblog($sitename, $foldername, $siteurl, $rssurl);
$fp = fopen('./'. $foldername .'/index.php', 'w+');
if( !fwrite($fp, "<?php require_once dirname(__DIR__) . '/autoblog.php'; ?>") )
if( !fwrite($fp, "<?php require_once '../autoblog.php'; ?>") )
$error[] = "Impossible d'écrire le fichier index.php";
fclose($fp);