Ferenc Engard wrote:
> In the case of failure the mysql.log is as follows:
> ------------------------------------------------------------
> 3 Query SELECT person.id,person.password
> FROM person,member WHERE person.username='author' AND person.sitegroup=0
> AND member.uid = person.id AND member.gid=0
This means that _before_ the call to mgd_auth_midgard the active
sitegroup allready is 0. This also explains why "author+sitegroupname"
works, where merely "author" doesn't. If we want to fix this we're going
to have to pinpoint where exactly the sitegroup info is being dropped.
We can do it by inserting print statements in your page code, or you can
apply the following patch to midgard-php4 to locate the problem. Only
use this for debugging on a non-SG0 host or you'll go nuts with all the
error reports.
Emile
Index: mgd_internal.h
===================================================================
RCS file: /usr/local/cvs/midgard/php4/mgd_internal.h,v
retrieving revision 1.13
diff -u -r1.13 mgd_internal.h
--- mgd_internal.h 2002/01/25 14:09:27 1.13
+++ mgd_internal.h 2002/03/10 21:17:55
@@ -48,6 +48,9 @@
if (!mgd_rcfg()) { \
RETURN_FALSE_BECAUSE(MGD_ERR_NOT_CONNECTED); \
} \
+ if (mgd_sitegroup(mgd_handle()) == 0) { \
+ fprintf(stderr, "Hey! Sitegroup now 0 @ %s line %d\n", __FILE__, __LINE__);
+\
+ } \
mgd_reset_errno(); \
} while (0);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]