[mapserver-users] Fatal error: Call to a member function setSize() on a non-object
Daniel Morissette
dmorissette at mapgears.com
Tue Jun 29 08:21:04 PDT 2010
Stefan Schwarzer wrote:
> Hi there,
>
> I am about to move my mapserver application from one (old) server to another (new) one. The old one was using mapserver 4.x, the new one the latest version. I copied the files over to the new server, eliminated the "dl("php_mapscript.so")", and in principal, I would have said, it should have worked.
>
> But it doesn't...
>
> It tells me "Fatal error: Call to a member function setSize() on a non-object". This happens on this line: $map -> setSize(900, 450);
>
> The phpinfo file tells me that Mapscript is loaded correctly. So, what can it be?
>
My first guess would be that your mapfile fails to load because of
something that changed between v4.x and the current (5.6) version. Look
at the other error messages that you get, starting with the first one.
If you don't get any error message other than the one you quoted above
(which would surprise me), then you could turn on log/debug and the logs
couold tell you more about what failed. See:
http://mapserver.org/optimization/debugging.html#steps-to-enable-mapserver-debugging
I'd also recommend that you have a look at the migration guide at
http://trac.osgeo.org/mapserver/browser/branches/branch-5-6/mapserver/MIGRATION_GUIDE.TXT
Daniel
--
Daniel Morissette
http://www.mapgears.com/
More information about the MapServer-users
mailing list