Closed andywebber closed 11 years ago
Is this issue topic still open? I also suffering from mismatch of "REDIRECT>.+?", which matches other markup that uses "~~". Attempt to match pageid fails due to the greediness of pattern ".+?".
I would like to propose "(REDIRECT>.*?|^#(?i:redirect) [^\n]+)".
It is sometimes useful to leave the old content in a page that is redirected (for posterity, for inclusion in search results, etc).
However, if the page includes any other markup which uses "
" notation, the pageredirect plugin fails badly (generates a blank page). The reason is that the regex used to match "REDIRECT>page~~" is greedy; it should be lazyTest case: page with:
See "Tips" under https://www.dokuwiki.org/devel:syntax_plugins#patterns
Pattern should perhaps be something like (?:
REDIRECT>.+?|^#(?i:redirect) [^\r\n]+), but I haven't tested this.