<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>2.0 Admin not working - GetCurrentSiteAddress() on a non-object</TITLE>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6000.16640" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=421380700-14052008><FONT face=Arial
color=#0000ff size=2>I tracked this problem down finally. It turns out
that if you set the directive register_globals to on in php.ini, then this will
be the result when trying to access server admin. In my case, I am
integrating an existing application (that I did not originally write) that
requires this directive be set to on. I'm really not sure if this is a bug
or not since I know that the use of this directive is a potential security risk
and not good practice.</FONT></SPAN></DIV>
<DIV> </DIV><!-- Converted from text/rtf format -->
<P><SPAN lang=en-us><FONT face=Tahoma size=1>Andy </FONT></SPAN><BR></P>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> mapguide-users-bounces@lists.osgeo.org
[mailto:mapguide-users-bounces@lists.osgeo.org] <B>On Behalf Of </B>Andy
Morsell<BR><B>Sent:</B> Tuesday, May 06, 2008 12:42 PM<BR><B>To:</B> 'MapGuide
Users Mail List'<BR><B>Subject:</B> [mapguide-users] 2.0 Admin not working -
GetCurrentSiteAddress() ona non-object<BR></FONT><BR></DIV>
<DIV></DIV><!-- Converted from text/rtf format -->
<P><FONT face=Arial size=2>Hi,</FONT> <BR><FONT face=Arial size=2>I have a
CentOS box configured with MGOS 2.0. Everything is working fine - standard
and flexible layouts display, the Sheboygan sample PHP application works with no
issues, the mapagent test pages work just fine, and so on. But, recently
(and it had been working at some point) Administrator stopped working. I
get the login page just fine, but after submitting the proper username and
password, I get:</FONT></P>
<P><B><FONT face=Arial>Fatal error</FONT></B><FONT face=Arial>: Call to a member
function GetCurrentSiteAddress() on a non-object in</FONT><B> <FONT
face=Arial>/usr/local/mapguideopensource/webserverextensions/www/mapadmin/servermanagement.php</FONT></B><FONT
face=Arial> on line</FONT><B> <FONT face=Arial>67</FONT></B><FONT face=Arial>
</FONT></P>
<P><FONT face=Arial size=2>Tracking this down a bit, that line is just:</FONT>
</P>
<P><FONT face=Arial size=2>$siteServerAddress =
$site->GetCurrentSiteAddress();</FONT> </P>
<P><FONT face=Arial size=2>So it looks like it is not ever properly creating an
MGSite object. Does anyone have any idea why this might be
occuring?</FONT></P>
<P><FONT face=Arial size=2>Thank you.</FONT> </P>
<P><FONT face=Tahoma size=1>Andy Morsell, P.E.</FONT> <BR><FONT face=Tahoma
size=1>Spatial Integrators, Inc.</FONT> <BR><A
href="http://www.SpatialGIS.com"><U><FONT face=Tahoma color=#0000ff
size=1>http://www.SpatialGIS.com</FONT></U></A> </P></BODY></HTML>