It is possible to display the _number_of_watching_users_ in the footer of every page. However, as an admin of my wiki, I have received numerous requests to also somehow dislay the WHO in addition to the HOW_MANY. Is there an existing hook/extension/feature of the wiki to extract and display that information?
Thanks, Paul.
On 10/11/07, Paul Grinberg gri6507@yahoo.com wrote:
It is possible to display the _number_of_watching_users_ in the footer of every page. However, as an admin of my wiki, I have received numerous requests to also somehow dislay the WHO in addition to the HOW_MANY. Is there an existing hook/extension/feature of the wiki to extract and display that information?
It is, of course, possible. However, it has not been implemented because it is objectionable from a privacy perspective.
The SQL Query you will require is: SELECT wl_user FROM watchlist WHERE wl_page=page_id where page_id is, obviously, the page_id of the page of interest.
On 11/10/2007, Andrew Garrett andrew@epstone.net wrote:
On 10/11/07, Paul Grinberg gri6507@yahoo.com wrote:
It is possible to display the _number_of_watching_users_ in the footer of every page. However, as an admin of my wiki, I have received numerous requests to also somehow dislay the WHO in addition to the HOW_MANY. Is there an existing hook/extension/feature of the wiki to extract and display that information?
It is, of course, possible. However, it has not been implemented because it is objectionable from a privacy perspective.
The SQL Query you will require is: SELECT wl_user FROM watchlist WHERE wl_page=page_id where page_id is, obviously, the page_id of the page of interest.
SELECT user_name FROM watchlist LEFT JOIN user ON wl_user = user_id WHERE wl_page = <page_id>
Rob Church
Rob Church <robchur@...> writes:
On 11/10/2007, Andrew Garrett <andrew@...> wrote:
On 10/11/07, Paul Grinberg <gri6507@...> wrote:
It is possible to display the _number_of_watching_users_ in the footer of
every
page. However, as an admin of my wiki, I have received numerous requests
to also
somehow dislay the WHO in addition to the HOW_MANY. Is there an existing hook/extension/feature of the wiki to extract and display that
information?
It is, of course, possible. However, it has not been implemented because it is objectionable from a privacy perspective.
The SQL Query you will require is: SELECT wl_user FROM watchlist WHERE wl_page=page_id where page_id is, obviously, the page_id of the page of interest.
SELECT user_name FROM watchlist LEFT JOIN user ON wl_user = user_id WHERE wl_page = <page_id>
Rob Church
What version of wiki is this for? I am running 1.9.3 and my watchlist table only has mysql> show columns in wiki_watchlist; +--------------------------+-----------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +--------------------------+-----------------+------+-----+---------+-------+ | wl_user | int(5) unsigned | NO | PRI | | | | wl_namespace | int(11) | NO | PRI | 0 | | | wl_title | varchar(255) | NO | PRI | | | | wl_notificationtimestamp | varchar(14) | YES | | NULL | | +--------------------------+-----------------+------+-----+---------+-------+
in other words, I don't have "wl_page".
On 12/10/2007, Paul Grinberg gri6507@yahoo.com wrote:
Rob Church <robchur@...> writes:
On 11/10/2007, Andrew Garrett <andrew@...> wrote:
On 10/11/07, Paul Grinberg <gri6507@...> wrote:
It is possible to display the _number_of_watching_users_ in the footer of
every
page. However, as an admin of my wiki, I have received numerous requests
to also
somehow dislay the WHO in addition to the HOW_MANY. Is there an existing hook/extension/feature of the wiki to extract and display that
information?
It is, of course, possible. However, it has not been implemented because it is objectionable from a privacy perspective.
The SQL Query you will require is: SELECT wl_user FROM watchlist WHERE wl_page=page_id where page_id is, obviously, the page_id of the page of interest.
SELECT user_name FROM watchlist LEFT JOIN user ON wl_user = user_id WHERE wl_page = <page_id>
Rob Church
What version of wiki is this for? I am running 1.9.3 and my watchlist table only has mysql> show columns in wiki_watchlist; +--------------------------+-----------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +--------------------------+-----------------+------+-----+---------+-------+ | wl_user | int(5) unsigned | NO | PRI | | | | wl_namespace | int(11) | NO | PRI | 0 | | | wl_title | varchar(255) | NO | PRI | | | | wl_notificationtimestamp | varchar(14) | YES | | NULL | | +--------------------------+-----------------+------+-----+---------+-------+
in other words, I don't have "wl_page".
Ah, right, both Andrew and I need a good slapping, then, and a re-read of the schema file. ;)
SELECT user_name FROM watchlist LEFT JOIN user ON wl_user = user_id WHERE wl_namespace = <namespace> AND wl_title = <title>
The namespace and title can be gotten from a Title object using Title::getNamespace() and Title::getDBkey().
Rob Church
Many thanks! If interested, please see http://www.mediawiki.org/wiki/Extension:WhoIsWatching for implementation.
What version of wiki is this for? I am running 1.9.3 and my watchlist table only has mysql> show columns in wiki_watchlist; +--------------------------+-----------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +--------------------------+-----------------+------+-----+---------+-------+ | wl_user | int(5) unsigned | NO | PRI | | | | wl_namespace | int(11) | NO | PRI | 0 | | | wl_title | varchar(255) | NO | PRI | | | | wl_notificationtimestamp | varchar(14) | YES | | NULL | | +--------------------------+-----------------+------+-----+---------+-------+
in other words, I don't have "wl_page".
I just confirmed that my database layout is correct for v1.9 (see http://www.mediawiki.org/wiki/Watchlist_table). So confusion still persists; which column/table are you talking about?
Thanks in advance, Paul
They understand that, they just forgot the new schema. See Rob's previous e-mail (where he talks him and Andrew neeeding a slapping) where he outlines a query that should work.
On 10/12/07, Paul grinberg gri6507@yahoo.com wrote:
What version of wiki is this for? I am running 1.9.3 and my watchlist
table
only has mysql> show columns in wiki_watchlist;
+--------------------------+-----------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default |
Extra |
+--------------------------+-----------------+------+-----+---------+-------+
| wl_user | int(5) unsigned | NO | PRI |
| |
| wl_namespace | int(11) | NO | PRI | 0
| |
| wl_title | varchar(255) | NO | PRI |
| |
| wl_notificationtimestamp | varchar(14) | YES | |
NULL | |
+--------------------------+-----------------+------+-----+---------+-------+
in other words, I don't have "wl_page".
I just confirmed that my database layout is correct for v1.9 (see http://www.mediawiki.org/wiki/Watchlist_table). So confusion still persists; which column/table are you talking about?
Thanks in advance, Paul
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/wikitech-l
wikitech-l@lists.wikimedia.org