dokufreaks/plugin-blog

How to exclude pages ?

Closed this issue · 5 comments

Hi,
Thanks for this great plugin.

I don't understand how to exclude pages. I wand to use one blog for all namespaces, and one blog by namespace. All blogs use start.txt files. But the general blog musn't to show namespaces blog. I try to parameter the excluded_pages to /start/ or !start!, but I've got this php error :
Warning: preg_match() [function.preg-match]: Delimiter must not be alphanumeric or backslash in /var/www/dokuwiki/lib/plugins/blog/helper.php on line 73

In a second way, I used {{tag>blog}} in my pages to exclude and use the refinement syntax in the general blog like this :
{{blog>:wistithi:blog?5 -blog}}
But this is ignored...

I think that instruction in line 73 is not continue, but break.

Thanks,
Thibaud.

Don't use delimiters: .*?start should work

$conf['plugin']['blog']['excluded_pages'] = '.*?start';

Warning: preg_match() [function.preg-match]: No ending delimiter '.' found in /var/www/dokuwiki/lib/plugins/blog/helper.php on line 73

Hmmm, just looked at the code again. It want's a delimiter :-(. try !.*?start! - if that doesn't work I'll reopen the bug and look into it.

That's work, but only at these condition : you have to replace "continue" by "break" in helper/php, line 73...

OK, it seems that it's better to keep "continue" if I don't want that some pages don't show... Now, all seems works perfect. But for how many times ? There is a problem of rights or cache or indexer that I don't understand very well...