5 * CopyRight 2002 Y.MASUI GPL2
6 * http://masui.net/pukiwiki/ masui@masui.net
8 * $Id: ls.inc.php,v 1.9 2004/07/31 03:09:20 henoheno Exp $
11 function plugin_ls_convert()
19 $args = func_get_args();
20 $with_title = in_array('title',$args);
23 $prefix = $vars['page'].'/';
26 foreach (get_existpages() as $page)
28 if (strpos($page,$prefix) === 0)
36 foreach ($pages as $page)
41 list($comment) = get_source($page);
43 $comment = preg_replace('/^(\*{1,3}.*)\[#[A-Za-z][\w-]+\](.*)$/','$1$2',$comment);
45 $comment = '- ' . preg_replace('/^[-*]+/','',$comment);
47 $ls[] = "-[[$page]] $comment";
50 return convert_html($ls);