Posted July 17, 200618 yr Can you please add the following functions to the sources/sql/mysql_admin_queries.php file:msg_get_cc_usersmsg_get_msg_posterThose two functions are used by the PM library functions when sending personal messages. Any mods or other addons inside the ACP that need to send PMs using the func_msg.php file will require those functions be present in the loaded cache file. Otherwise the mods have to do a less elegant workaround like inserting the PM stuff using a few custom DB queries.
July 17, 200618 yr Hmm, I suppose a better idea would be to add them to the extra queries file, and then load that when needed.There are a couple duplicated queries, but it really isn't ideal to do that - better to put it in a shared location.
July 18, 200618 yr Are the extra queries always loaded? My concern is that by using the func_msg.php, it calls the cached queries using the cache_add_query function, but doesn't pass in the third argument that function uses, $method. So that argument will always be 'sql_queries', when it looks like functions in the extra queries file always pass in 'sql_extra_queries' as that third argument.
July 20, 200618 yr Yes, we'd have to make some adjustments, certainly. ;) But it would probably be better than duplicate queries (which, admittedly, I think added a couple of in 2.2 already).
October 18, 200618 yr So I see this wasn't added then. Bummer, will have to include the edit to add these functions in my mods still.
October 18, 200618 yr Wizzy and I were discussing this (and things like it) and really what we need to do is start moving more away from the cache files, since the DB driver can handle so much of this stuff now.
October 19, 200618 yr That would be ideal, since the root of the problem that led to this topic was the fact that the func_msg class has calls to a couple cached queries that aren't present in the cache file loaded in the ACP, meaning you can't use that class to send PMs from the ACP without adding these functions to the mysql_admin_queries.php file.
October 19, 200618 yr Yeah - originally in the driver, I don't think it properly supported joins, or something of that nature. Now it's not a problem of course, but we still have queries in the cache file. Will work on this as time goes on.
Archived
This topic is now archived and is closed to further replies.