karig I'm fiddling with my template and want to be able to insert the names of pages in a given namespace (using PHP and the DokuWiki functions). I know how to get the IDs and namespaces of pages; I use getID() and getNS(), or just get $conf['datadir'] and use glob() to get filenames. But what if I want to grab the title of a page? The popup window that appears when you click the internal-link button in the wiki editor can display both the ID and the title of (or rather the first H1 header in) each page in a namespace. Is there a nice way for a template page to grab this title for a given page ID, or do I basically just open the data page file as a text file and match a regular expression like /======([\sA-Za-z0-9]*)======/ ? I tried the tpl_pagetitle() function, but I just got back the page ID with a '1' added to the end of it. What I want is if the page ID is "site:projects:to_do" and the first header on the page is "====== To do ======", then I get back "To do".
andi For development questions like these, better use the mailing list. What you're looking for is probably p_get_first_heading(). In general you probably want to learn about metadata in DokuWiki. I hope you know about the general environment already.