What follows is some basic instructions on how to get the kit up and running. You have downloaded the file now haven't you?
We will assume your Unix box is running and that you have Apache and SAMBA installed and running. See their documentation for details on how to do this. That bit's important..
Also, seeing as Im using ArcView under Windows 95 (the RPC seems more stable than under NT, bizarrely), then the following instructions will assume this. Well assume your Unix host running Apache and SAMBA is called gis02, and your AV copy is running on W95 and is called sp_solo (Han's cousin). So...
For simplicity, install Apache in the default directory /usr/local/etc/httpd. From here, you will be interested in ./cgi-bin and ./htdocs.
In cgi-bin, place the following:
Avclient.c
av-cgi
Compile avclient.c, but before you do, make sure the paths in the INCLUDE lines point to the right places for rpc.h etc..
The command I used to do this was
CC -O -o avclient avclient.c
Under Solaris using gcc, you need
gcc -o avclient avclient.c -lnsl
Make sure av-cgi is set as executable.
In the htdocs sub, make another directory called "gifs". Share it via SAMBA (see sample SAMBA config file)
Edit your av-cgi file changing all occurences of sp_solo to your av-pc name. Don't forget to get all occurences - it occurs in the VBScript part as well...
In your AV program group, run the PortMapper application (not needed under Unix AV). Then start ArcView and load the project in the zip file. As mentioned before, this whole deal seems to be more stable under Win95 than WinNT so if you can, devote a W95 machine to the cause. Leave the portmapper running at all times.
With the Main View open, and under the Map Server menu, click the SizeWin option (change the AMS.SizeWin script if the resultant image is not your desired size)
Load in your coverages and set scale cutoffs etc so that as you zoom in, the layers change etc blah blah..
Export a test bitmap to the SAMBA share. Load this up in PhotoShop, XV or PSPro or any program that will tell you the exact width x height in pixels of the image remember, its not the size in the SizeWin script as it doesnt take into account the border size (thanks ESRI).
Click the M on the toolbar to see the number of meters you can fit in your window at a scale of 1:100,000 (ImageMeters). Remember, our UK mapping coordindate system doesn't use Projections, so any maths about where in the world we are takes that into account.
Modify the av-cgi file changing the entries for StandardGIFHeight, StandardGIFWidth and ImageMeters to be the height, width (both in pixels) and the number in meters from the AV dialog box from above.
Change the AMS.ExportGIF script for the right paths to BMP2GIF (I put it in c:\win95\command) and where the resultant BMP and GIF file will go. Make sure you send your GIF to the part in the Unix directory tree under htdocs/gifs. ie. /usr/local/etc/httpd/htdocs/gifs. The part that erases the WMF file is the temporary file AV makes and then doesn't clean up when exporting (thanks ESRI) and it is made in your working directory (check from File, Set Working Directory)
Note: If you have ArcView 3.1, you can now amend the AW.ExportGIF script to export a JPEG instead. It saves calling any other programs and is great..
Under the Main View, Map Server, click on Start Server.
Go back to your Apache cgi-bin directory. Type the following
./avclient sp_solo av.getactivedoc.asstring
You should see the name of the window currently open in ArcView. You are either happy or un-happy at this point. If you didn't see anything back, then have a look at this..
What - you're still here? Then it must have worked. Therefore:
Go to Internet Explorer, enter the address. Basically, a good starting point is
http://gis02/cgi-bin/av-cgi?cmd=fullextent&x=0&y=0&scale=0
Remember gis02 is your WWW servername, not AV server.
If all goes well, your av server will draw a map and youll see it quickly run the BMP2GIF program. Youll then get a map back I hope. Go back to the Q&A page if not.
You need to check that the X and Y boxes are updating with your co-ordinates as you move over the map. If they aren't, then you're probably using IEX4 which needs slightly different code for the image move stuff.