Commit f5a748b4 authored by Pablo Rauzy's avatar Pablo Rauzy
Browse files

fix relative links to index.html files

parent 143cae1c
......@@ -190,7 +190,7 @@ function render ($file, $mode='edit', $entry_dt='NEW') {
array($settings['title'], $groups[$group]['name'], $page['title']),
$settings['title_bformat']);
$title_url = str_replace(array('%site%', '%group%', '%page%'),
array(empty($relroot) ? '/' : $relroot, ($group == -1) ? $settings['url'] : $relroot.preg_replace('/\/?index\.html$/', '/', $group_file), $relroot.preg_replace('/\/?index\.html$/', '/', $page['file'])),
array(empty($relroot) ? '/' : $relroot, ($group == -1) ? $settings['url'] : $relroot.preg_replace('/index\.html$/', '', $group_file), $relroot.preg_replace('/index\.html$/', '', $page['file'])),
$settings['title_bformat']);
if ($mode == 'publish') { ob_start(); }
?><!doctype HTML>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment