About issue 19

0 views
Skip to first unread message

Rouslan Placella

unread,
Jul 5, 2011, 2:14:07 PM7/5/11
to geeklo...@googlegroups.com
Dengen has reported [1] that other geeklog plugins have problems with
the fact that we changed the way we reference DB tables from
$_TABLES['gf_foo'] to $_TABLES['forum_foo']. He also proposed that we
revert to using the old references to tables. I think that it's not such
a great idea, especially since we already have a beta out. Anyway, I
think that we should not revert, but just create an extra copy of the
references to tables in functions.inc, then get in touch with authors of
the affected plugins and tell them that the old tables references are
deprecated and will be removed in a future version of the forum and that
they should start using the new ones ASAP. Your thoughts?

The code at the top of forum's functions.inc might end up looking like
this:
--- SNIP ---
/**
* Add to $_TABLES array the tables forum plugin uses
*/
$_TABLES['forum_userprefs'] = $_DB_table_prefix . 'forum_userprefs';
$_TABLES['forum_topic'] = $_DB_table_prefix . 'forum_topic';
$_TABLES['forum_categories'] = $_DB_table_prefix . 'forum_categories';
$_TABLES['forum_forums'] = $_DB_table_prefix . 'forum_forums';
$_TABLES['forum_watch'] = $_DB_table_prefix . 'forum_watch';
$_TABLES['forum_moderators'] = $_DB_table_prefix . 'forum_moderators';
$_TABLES['forum_banned_ip'] = $_DB_table_prefix . 'forum_banned_ip';
$_TABLES['forum_log'] = $_DB_table_prefix . 'forum_log';
$_TABLES['forum_userinfo'] = $_DB_table_prefix . 'forum_userinfo';
/**
* Deprecated references to tables. Do not use these,
* as they will be soon removed.
*/
$_TABLES['gf_userprefs'] = $_DB_table_prefix . 'forum_userprefs';
$_TABLES['gf_topic'] = $_DB_table_prefix . 'forum_topic';
$_TABLES['gf_categories'] = $_DB_table_prefix . 'forum_categories';
$_TABLES['gf_forums'] = $_DB_table_prefix . 'forum_forums';
$_TABLES['gf_watch'] = $_DB_table_prefix . 'forum_watch';
$_TABLES['gf_moderators'] = $_DB_table_prefix . 'forum_moderators';
$_TABLES['gf_banned_ip'] = $_DB_table_prefix . 'forum_banned_ip';
$_TABLES['gf_log'] = $_DB_table_prefix . 'forum_log';
$_TABLES['gf_userinfo'] = $_DB_table_prefix . 'forum_userinfo';
--- SNIP ---

Rouslan

[1]: http://code.google.com/p/geeklog/issues/detail?id=19

Yoshinori Tahara

unread,
Jul 6, 2011, 8:31:18 AM7/6/11
to geeklo...@googlegroups.com
I think this is a good solution.

2011/7/6 Rouslan Placella <rou...@placella.com>:

> --
> You received this message because you are subscribed to the Google Groups "Geeklog Forum" group.
> To post to this group, send email to geeklo...@googlegroups.com.
> To unsubscribe from this group, send email to geeklog-foru...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/geeklog-forum?hl=en.
>
>

--
dengen

Tom

unread,
Jul 6, 2011, 8:52:38 AM7/6/11
to Geeklog Forum
Then lets use it since it is a simple fix. If possible we should get
the authors of these plugins to use PLG_getItemInfo to retrieve
information from the forum instead of accessing the tables directly.
If the information they need from the forum is not available from
PLG_getItemInfo get them to enter a feature request for it.

Tom

On Jul 6, 8:31 am, Yoshinori Tahara <denge...@gmail.com> wrote:
> I think this is a good solution.
>
> 2011/7/6 Rouslan Placella <rous...@placella.com>:

Joe Mucchiello

unread,
Jul 7, 2011, 10:12:20 AM7/7/11
to geeklo...@googlegroups.com
As a heads up: this could cause issues with db backup scripts that use the
$_tables var to find out what tables to backup. I don't know if such a db backup
system is still in use. But I know at one time there was a plugin that did
database backups that way. But I have no idea how "current" my information is. I
don't use such a db backup tool.

Reply all
Reply to author
Forward
0 new messages