Pima County Geographic Information Systems logo

Pima County GIS - Pima County MapGuide MWF Wrapper

Pima County Experience Using the Wrapper

Pima County has a large MapGuide user base of internal and public users. We wanted the function of the MapGuide MWF Wrapper for years and kept hoping that somebody else would do it -- especially Autodesk. In the end, we must have wanted it more than anyone else.

We wanted this code for a long time because we didn't want copies of the basic HTML all over our web site with different maps. We also didn't want maps implemented that only worked with Internet Explorer. We wanted all our MapGuide maps to work with all supported browsers. We also didn't want users bombing out because their MapGuide Viewer wasn't up-to-date. We wanted to be able to fix code problems for all our maps in one place. Further, we refused to just point to the latest ActiveX control and force it on our users while they sat there wondering why their screen was blank, not knowing a new version was downloading. The Wrapper solves these problems.

While we have upgraded our MapGuide server with each new release, we kept our MWF's at 5.0 for a long time because the user upgrades were so traumatic and we didn't need new Viewer function. When the Wrapper was first completed, our server was running 6.3 and we required the 5.0 Viewer with 5.0 MWF files. We then used the Wrapper to upgrade the user base (several thousand users since we're a public site) to Viewer 6.3 while keeping the MWF at 5.0. We couldn't believe how many people had not upgraded despite the many notices on our web site prior to that time. After the users had plenty of time to do the recommended upgrade, we changed the MWF to 6.3 and set 6.3 as the required version in the Wrapper settings file. Shortly after that, 6.5 was announced, we waited a month or so, and started the process over and had confidence that we weren't causing undue problems for our users. We've used the Wrapper for two upgrades and it was very smooth. The biggest problem is users without administrator rights as the Wrapper has no way to detect that and users either don't read or don't understand what "Administrator rights" means. Users also had poor download times from Autodesk's servers. We now serve the ActiveX Control CAB file from our web server rather than relying on Autodesk and things are much smoother.

The Wrapper has helped our users (and us) through two MapGuide Viewer version upgrades so far, and has made the installation process trivial for many new users -- all while maintaining common code encapsulating all our MapGuide maps. When we first put the Wrapper on our site, we upgraded end-user MapGuide Viewers for a great many (perhaps the majority) users who never heeded our upgrade messages and popups. With the Wrapper, it gets their attention and makes it easy for most to do the upgrade. The Wrapper has also allowed us to start using the MapGuide API without having custom encapsulating pages for each map that uses the API. In fact, some "new maps" are actually old maps that are just customized at run time by the API so show a particular view or layers. We've even used the API with the Wrapper to add sensitive layers dynamically from MLF's to a base map for selected users.

A big advantage of the Wrapper for Pima County is that we have a number of separate maps. Now they all share the same code for MWF display. Maintenance is much easier and every map gets all the function of the Wrapper.

We resisted using the MapGuide API for a long time until we wrote the Wrapper which allows API map customization with near trivial effort and easy maintenance. For example, see our three Sonoran Desert Conservation Plan maps where, in fact, there is only one MWF and the user's view is set by the API at run time, adjusting things like turning layers on as needed. It looks like three maps to the user, but there's just one MWF file.

The Wrapper provides for picking up MapGuide API code dynamically. Therefore, to add API function to any map, all we have to do is write the unique API code for the desired function and tell the Wrapper where to find the API code with a URL parameter. (Particular API applications may also need form controls added to the title frame or in another new frame.)

We aren't actively using the Dynamic Authoring Toolkit at this time. We would like to get to the point where our MWFs are all created dynamically from a single set of layers. Now, when one layer is on many maps, if we make a change to the layer in Author, we have to find the other MWFs with that layer and make changes there too. This is both tedious and difficult. We would rather have the layer defined once and then used to generate our various MWF files.

The API and the Wrapper help with this need to some extent by reducing the number of MWFs we need. If a new map should be the same as another one, but only needs one or two layers added, then we can use the old map and use the API to add the layers from MLFs when the user loads the map. Or, we can use the API to customize an existing may when the map is loaded to zoom to a certain area and turn certain layers on and off to make it look like a "new" map. The Wrapper is a big help with this since we create only the API code for the new map and don't copy the rest of the map page structure.

Back button Pima County MapGuide MWF Wrapper Main Page