User talk:JimHu

Userrightslist errors
Hope you get this. What do you think is causing these errors?:

Notice: Undefined property: UserRightsList::$username in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 239

Notice: Undefined property: UserRightsList::$yearfrom in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 243

Notice: Undefined property: UserRightsList::$yearto in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 250

Notice: Undefined property: UserRightsList::$requestedGroup in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 131

Notice: Undefined property: UserRightsList::$requestedGroup in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 131

Notice: Undefined property: UserRightsList::$requestedGroup in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 131

Notice: Undefined property: UserRightsList::$username in ...\extensions\UserRightsList\SpecialUserRightsList.body.php on line 140
 * should be fixed in 0.2 --JimHu 20:08, 10 February 2008 (UTC)

UserRightsList bug
Hi Jim, thanks for making the UserRightsList extension; from what I've seen it looks cool and I'd really like to test it. However, after I add the require_once call, I get this:

The wiki is running on MediaWiki 1.11.

P.S. You might want to remove the ending ?> tags, they haven't been used since 23531. :-) -- Sayuri 20:37, 10 February 2008 (UTC)
 * But return true is at the end of that function! (I'm still on 1.9x - been meaning to upgrade). --JimHu 21:40, 10 February 2008 (UTC)

Database Error
Hi Jim,

I am using Mediawiki 1.11. When installing UserRightsList 0.22, I get a database error: MySQL returned the error "1142: SELECT command denied to user 'cdy'@'srv83.one.com' for table 'user' (localhost)". What could possibly go wrong?

Regards, Corne
 * Hi Corne, that seems very odd, as UserRightsList is using the regular MW db connection to access the table. Can you tell where in the UserRightsList scripts it's failing.  Could you also describe what happens with more details - does it break the wiki completely, or only fail when you try to access the special page? --JimHu 23:30, 27 February 2008 (UTC)


 * Hi, I get the same error when I try to access UserRightList from the special pages. The function mentioned in my error message is an empty string (""), maybe that's relevant. The wiki's database is still ok. The problem seems to be that the script tries to access the wrong table, because when I give "ALL PRIVILEGES" as permissions for the user and all MySQL databases, the error message changes to: "1146: Table 'mw_.user' doesn't exist (localhost).". Regards --Laudrin 12:06, 27 March 2008 (UTC)
 * Forgot the version numbers: MediaWiki: 1.11.2, PHP: 5.2.6RC1-pl1-gentoo (apache2handler), MySQL: 5.0.54-log, UserRightsList: 0.22. --Laudrin 12:31, 27 March 2008 (UTC)
 * Interesting. I'll get back after I ask about it on one of the mediawiki lists.--JimHu 14:10, 27 March 2008 (UTC)

UserRightsList
JimHu, are you interested in having UserRightsList committed to Wikimedia's Subversion, or if not another repo? Then it can be fixed up (I honestly don't understand how some of that code could actually work, the SQL statements themselves defy the definition of a database prefix), and if in Wikimedia's SVN will also have good translation support. Dantman

Yes, I think it would be of general interest, and I'd love the help with making it more generally usable. I wrote it to deal with our own user management issues, and we don't use db prefixes, so I don't know that it even works with them at all. --JimHu 15:05, 7 May 2008 (UTC)


 * Ok, when I get back home or to my dad's (I'm currently on a school computer) I'll commit the raw code. I'll probably tweak things to standards after that and look into actually fixing up the extension itself.
 * Ya... for the prefixes... You're basically using "$wgDBprefix.tablename"... However a prefix is actually defined as "{$wgDBprefix}tablename" so the honest truth is if someone set the prefix to something, then MySQL would output errors saying that it can't find the database with the same name as $wgDBprefix. In this case you're actually supposed to be using Database::tableName(s,N) to get the name of the table for you and then use the outputted variables to build your SQL queries. Dantman 23:51, 7 May 2008 (UTC)