* Don't consider links to anchors on the same page to be self links.
Patch by Daniel Burrows. Closes: #451729 * When usedirs is disabled, link direct to index.html files, not to directories, to improve browsing of file:// urls. Patch by Daniel Burrows. Closes: #451728master
parent
9dd5285025
commit
d00e8d78c8
|
@ -514,7 +514,9 @@ sub displaytime ($;$) { #{{{
|
||||||
sub beautify_url ($) { #{{{
|
sub beautify_url ($) { #{{{
|
||||||
my $url=shift;
|
my $url=shift;
|
||||||
|
|
||||||
|
if ($config{usedirs}) {
|
||||||
$url =~ s!/index.$config{htmlext}$!/!;
|
$url =~ s!/index.$config{htmlext}$!/!;
|
||||||
|
}
|
||||||
$url =~ s!^$!./!; # Browsers don't like empty links...
|
$url =~ s!^$!./!; # Browsers don't like empty links...
|
||||||
|
|
||||||
return $url;
|
return $url;
|
||||||
|
@ -562,7 +564,8 @@ sub htmllink ($$$;@) { #{{{
|
||||||
}
|
}
|
||||||
|
|
||||||
return "<span class=\"selflink\">$linktext</span>"
|
return "<span class=\"selflink\">$linktext</span>"
|
||||||
if length $bestlink && $page eq $bestlink;
|
if length $bestlink && $page eq $bestlink &&
|
||||||
|
! defined $opts{anchor};
|
||||||
|
|
||||||
if (! $destsources{$bestlink}) {
|
if (! $destsources{$bestlink}) {
|
||||||
$bestlink=htmlpage($bestlink);
|
$bestlink=htmlpage($bestlink);
|
||||||
|
|
|
@ -18,8 +18,13 @@ ikiwiki (2.13) UNRELEASED; urgency=low
|
||||||
* Fix mercurial historyurl in example setup file.
|
* Fix mercurial historyurl in example setup file.
|
||||||
* More compact output for the brokenlinks plugin.
|
* More compact output for the brokenlinks plugin.
|
||||||
* Allow trailing slashes after page names in wikilinks.
|
* Allow trailing slashes after page names in wikilinks.
|
||||||
|
* Don't consider links to anchors on the same page to be self links.
|
||||||
|
Patch by Daniel Burrows. Closes: #451729
|
||||||
|
* When usedirs is disabled, link direct to index.html files, not to
|
||||||
|
directories, to improve browsing of file:// urls.
|
||||||
|
Patch by Daniel Burrows. Closes: #451728
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Sat, 17 Nov 2007 16:26:14 -0500
|
-- Joey Hess <joeyh@debian.org> Sat, 17 Nov 2007 19:56:46 -0500
|
||||||
|
|
||||||
ikiwiki (2.12) unstable; urgency=low
|
ikiwiki (2.12) unstable; urgency=low
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue