smiley: Generate links relative to the destpage. (Fixes a reversion from 2.41.)

master
Joey Hess 2008-06-28 16:58:31 -04:00
parent 1ab9eb3420
commit 00503f25cd
3 changed files with 9 additions and 1 deletions

View File

@ -76,7 +76,7 @@ MATCH: while (m{(?:^|(?<=\s|>))(\\?)$smiley_regexp(?:(?=\s|<)|$)}g) {
else {
# Replace the smiley with its expanded value.
substr($_, $spos, length($smiley))=
htmllink($params{page}, $params{page},
htmllink($params{page}, $params{destpage},
$smileys{$smiley}, linktext => $smiley);
}
}

2
debian/changelog vendored
View File

@ -20,6 +20,8 @@ ikiwiki (2.51) UNRELEASED; urgency=low
* Add support for the universal edit button <http://universaleditbutton.org/>
(To get this on all pages of an exiting wiki, rebuild the wiki.)
* txt: New plugin, contributed by Gabriel McManus.
* smiley: Generate links relative to the destpage. (Fixes a reversion from
2.41.)
-- Joey Hess <joeyh@debian.org> Sun, 15 Jun 2008 15:03:33 -0400

View File

@ -12,3 +12,9 @@ What about if I have main inline page, for example
Do you have any idea how to fix it? I dont't want to have multiple
`smileys` directory, of course :) --[[Paweł|ptecza]]
> I see that I broke this in commit
> 0b9e849aba38f0695491ad5ca27de11632627ffe, presumably because a) sanitize
> filters didn't get destpage at the time and b) I didn't think through
> what that meant. Luckily, in the meantime, I added destpage to santize's
> parameters, so it was easy to fix. [[done]] --[[Joey]]