Hi Chris,

it took me many hours to get cartoweb running under IIS, just to find out that some plugin (I think it was the pdf export) did not work under our IIS configuration. Finally, I switched back to Apache.

Anyway, I install PHP, mapserver and cartoweb the following way:
  1. Get PHP running under IIS or Apache. There is a documentation on php.net that works. If you are working with virtual directories you must either set or not set or not set doc_root in php.ini. I can not remember which one is correct - try. If I am not mistaken it is the opposite of what some documentation said.
  2. Setup error logging if it is not in php.ini. I usually log to a file, i.e. "log_errors = On" and error_log = "{SOME_PATH}\php.log".
  3. Get a ms4w package from http://www.maptools.org/ms4w/. Make sure it fits your PHP version. If you have 5.2.x the current ms4w 2.2.4 should work. Decompress it into some temp folder.
  4. Create a folder "Mapserver" somewhere and add it to the Windows PATH variable. This way you do not need to put the dlls required by mapserver into the Windows system path. Now log out an in again or reboot if possible, so Windows rereads the system variables and the new PATH is recognized.
  5. Now get Dependency Walker from http://www.dependencywalker.com/ and extract it somewhere. You will need it in step 8.
  6. Get php_mapscript.dll from the ms4w package. It is located unter {MS4W_TEMP_PATH}\Apache\php\ext. Copy it to the ext folder of your PHP installation. I usually rename it to something like php_mapscript_4.10.2.dll, so I know which version is currently installed. Load the extension in the php.ini, e.g. "extension=php_mapscript_4.10.2.dll". Make sure, that extension_dir is correctly set in php.ini.
  7. Copy the proj folder from ms4w and its content to C:\.
  8. Finally, the libraries required by php_mapscript.dll have to be copied to the folder created in step 4. In order to do this run depends.exe and open php_mapscript.dll. It will tell you which dlls are missing. Copy them from {MS4W_TEMP_PATH}\Apache\cgi-bin to the folder created in step 4. Refresh the view in Dependency Walker after copying, because there might be additional requirements. Repeat this until no more missing dependencies are reported. You may savely ignore dlls that show the timer, e.g DWMAPI.dll, SHLWAPI.DLL.
Now, php should be able to load the Mapscript extension. Check it with the phpinfo() function. If it does not, I have no idea why, could be a version conflict or a wrong dll. It's difficult to determine without seeing the actual system.

If mapscript is loaded, you should be able to install Cartoweb according to the documentation.

I hope this helps a bit.


Regards,
Dirk




Chris Duncan, GISmatters wrote:
I've been asked to work on an existing Mapserver site, including redeploying it as a Cartoweb project. I have solid if not extensive experience with web application development (PHP, MySQL, Mapserver, ASP, ASP.NET), but not much experience with server setup and maintenance. After a full 2 days of reading and experimenting, I still cannot get a basic Cartoweb demo to run... hope I can get some pointers to get setup.

The existing configuration is Windows Server 2003, IIS 6.0, Mapserver 4.6.0, PHP 5.1.2.  There is a functioning Mapserver website running. My first goal is to install Cartoweb and run the demos.

I downloaded cartoweb-withdemo-3.3.0.zip and unzipped it in it's own new directory.

First of all, I cannot get the "prerequisites" going. I have copied php_mapscript.dll to the PHP extensions directory, I have made sure that cgi.force_redirect=0. When I go to cartoweb3 info.php I get the error message "WARNING: can't load mapscript library".

Nonetheless, after wrestling with that problem for too long, I tried to continue with the cartoweb install, hoping that maybe I'd gain some more insight or ideas in the process. I executed the basic setup command:

php cw3setup.php --install --base-url http://umaacorn.provost.ads.umass.edu/acorncw/cartoweb3/htdocs

but I get blank windows when I go to client.php or demoCW3.php... they load but there's no HTML content.

I have tried dozens of other things - messing around with the IIS configuration (currently it seems to be using php5isapi.dll, so I've tried php-cgi.exe with no luck, but maybe I didn't set it up right).

I would love to have a step-by-step or a checklist to go by... but will settle for help of any kind!  Hope someone out there with similar setup and/or experience will lend a hand, and I'll be glad to return favors in the future!

Cheers,

Chris

--

Chris Duncan, Ph.D.
President
GISmatters

[EMAIL PROTECTED]
http://www.gismatters.com/

1 Tuckerman Ln
Amherst, MA 01002

Tel: 413-549-2052
Fax: 508-637-2557

_______________________________________________
Cartoweb-users mailing list
[email protected]
http://lists.maptools.org/mailman/listinfo/cartoweb-users

_______________________________________________
Cartoweb-users mailing list
[email protected]
http://lists.maptools.org/mailman/listinfo/cartoweb-users

Reply via email to