Wiki Links Posted by gray 17 Jul 2004 10:10 GMT-0000 posts: 32 Is there any way to get a list of needed Wiki pages? I mean a list of pages which there are links to, but do not yet exist. - Gray
Posted by Damian Parker 17 Jul 2004 10:51 GMT-0000 posts: 2881 Hi Under some of the Tiki versions there are tiki-orphan_pages.php, they could be listed on that. Damian
Posted by Terence? 17 Jul 2004 17:09 GMT-0000 posts: 71 I believe orphan pages are wiki pages that exist but not linked to from anywhere. gray is looking for a list of wikiwords that do not link to existing pages, I think. There is no such feature (yet).
Posted by gray 17 Jul 2004 17:37 GMT-0000 posts: 32 Ah, yes. I'm looking for a list of WikiWords which do not link to existing pages. The feature not existing explains why I couldn't find it. 😊 Thanks. - Gray
Posted by Amedee Van Gasse 17 Jul 2004 22:42 GMT-0000 posts: 59 I have seen this question before on this forum, only a couple of weeks ago I think. If you browse back, you might find a solution. And please dev people like Damian: this sounds like a good feature, please add it if it's not too much work. 😉
Posted by Amedee Van Gasse 17 Jul 2004 22:50 GMT-0000 posts: 59 Try this link: http://tikiwiki.org/tiki-view_forum_thread.php?comments_parentId=8716&forumId=4
Posted by gray 20 Jul 2004 21:44 GMT-0000 posts: 32 Thanks for the pointer avgasse. I've borrowed that idea. If anyone is interested the SQL i've used to list wanted pages is: Copy to clipboardselect tiki_links.toPage from tiki_links left join tiki_pages on (tiki_links.toPage = tiki_pages.pageName) where tiki_pages.pageName is null; - Gray
Posted by gray 21 Jul 2004 12:37 GMT-0000 posts: 32 The full solution I used was this quick hack of a Wiki plugin: (save as lib/wiki-plugins/wikiplugin_wantedpages.php) (you will also need to add the start and end php tags) Copy to clipboard// wikiplugin_wantedpages.php // Display "wanted" Wiki pages // grk@ducked.net // Usage: {WANTEDPAGES()}{WANTEDPAGES} require_once "lib/wiki/pluginslib.php"; function wikiplugin_wantedpages_help() { return tra("Lists ''wanted'' Wiki pages\n"); } function wikiplugin_wantedpages($data, $params) { $plugin = new WikiPluginWantedPages(); return $plugin->wantedpages($data, $params); } class WikiPluginWantedPages extends PluginsLib { function wantedpages($data, $params) { global $wikilib; $query = "select tiki_links.toPage from tiki_links"; $query .= " left join tiki_pages on (tiki_links.toPage = tiki_pages.pageName)"; $query .= " where tiki_pages.pageName is null;"; $result = $wikilib->query($query,array()); $out = array(); while ($row = $result->fetchRow()) { $out[] = '(('.$row['toPage'].'))'; } sort($out); return implode('',$out); } }