Loading...
 
Skip to main content

Custom Share Module 0.1dev

Features / Usability

Features / Usability


Re: How to get a "WantedPages" list like in PHPWiki?

posts: 23 Germany

I did something like this by modifying thewiki sql plugin. Look into the lib/wiki-pluigns/ Directory. Understanding the db-scheme to get a list of wanted wiki pages is easy.
I created a ne plugin file called wiki-emptypages.php with the function emptypages in it. Now I can call it with
{EMPTYPAGES(db=>wikidb,search=>%,first=>0,count=>150)}{EMPTYPAGES}
It returns a list as table with the names of the pages most wanted, with the comment form where and how often they are wanted. The search param let you get only pages fitting to this search condition (sql like statement for wiki page name), the count defines how many items you want to display and first let get you the second page ...
But be warned it is a quick and dirty hack, you need to be allowed to you use wiki-plugins and DSN.
You need to define a DSN for the db=> statement. In my case I defined a DSN wikidb and created a db user who has just the rights to read the needed tables and cols and nothing else! So security risk is not to big!
The code of the plugin (lib/wiki-plugins/wikiplugin_emptypages.php):

There are no comments at this time.

Upcoming Events

1)  18 Jul 2024 14:00 GMT-0000
Tiki Roundtable Meeting
2)  15 Aug 2024 14:00 GMT-0000
Tiki Roundtable Meeting
3)  19 Sep 2024 14:00 GMT-0000
Tiki Roundtable Meeting
4) 
Tiki birthday
5)  17 Oct 2024 14:00 GMT-0000
Tiki Roundtable Meeting
6)  21 Nov 2024 14:00 GMT-0000
Tiki Roundtable Meeting
7)  19 Dec 2024 14:00 GMT-0000
Tiki Roundtable Meeting