I assumed that you were referring to the 'Itasca Demo' that I referenced in my message, a simple html demo without javascript. You are working with a demo interface that uses javascript to craft URL calls for things like scalebar, reference, etc. It is not part of the MapServer CGI, just an example of how one person built an interface using one of the many different ways to build a MapServer interface.
The box in the reference map is drawn by the MapServer CGI, it is not done in the interface with javascript. Does your 'box of interest' show up when you zoom in? If the extent of your reference map is not set wide enough, the box may fall outside of your reference image and not appear. If this is the case, it should show up as you zoom in though. If the box doesn't appear after you project the data, are the reference map units (and projection) the same as the output projection and units for your map file? (in the projection block at the top of your map file) -----Original Message----- From: Stephen Davies [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 08, 2005 11:20 PM To: Fawcett, David; [email protected] Cc: Stephen Woodbridge Subject: Re: [UMN_MAPSERVER-USERS] mode etc documentation Thanks for the feedback but the references you give don't really answer my questions. The CGI reference lists the modes (I had seen this list but didn't realise that it was THE list) but says nothing to explain how/why the tutorial code works: document.scalebar_kilometers.src = MapServer + "?map=" + ms.mapfile + "&map_scalebar_units=kilometers&mode=scalebar&mapext=0+0+" + (ms.extent[2] - ms.extent[0]) + "+" + (ms.extent[3] - ms.extent[1]) + "&mapsize=" + ms.width + "+" + ms.height; Clearly scalebar mode uses the "size" of the map and the size of the image to do it's job but the doco doesn't say anything about the extent change. I see nothing in the Mapfile reference to do with code. My current application works fine except that the "box of interest" does not display on my reference map when I project the data. I had to make a number of changes to get the demo javascript code to work with southern hemisphere data and want to check to see if there is a similar problem with this. Is the box drawn by mapserv reference mode or by javascript? I would expect it to be in the javascript but cannot see it. I understand what you say about the two extents and have just found the javascript code that uses them. I have read/run pretty much all of the doco/demos at umn etc and have made good progress in getting my application up and running. There are just a few bits and pieces that I still need. Cheers and thanks, Stephen On Wed, 9 Nov 2005 01:53 pm, Fawcett, David wrote: > Comments in-line > > > -----Original Message----- > From: UMN MapServer Users List on behalf of Stephen Davies > Sent: Tue 11/8/2005 8:55 PM > To: [email protected] > Subject: [UMN_MAPSERVER-USERS] mode etc documentation > > G'day again. > > A couple more questions please. > > Where are the various mapserv modes documented? > > I see references to map, query, scalebar, legend modes but cannot find > details of exactly what each one does and which mapfile entries are used and > whether there are any more modes available. > > DF: Take a look at: http://ms.gis.umn.edu/docs/reference/cgi/controls scroll down to 'Mode' > > Where is the code that draws the "box of interest" on the reference map? > > DF: http://ms.gis.umn.edu/docs/reference/mapfile/reference > > What is the relationship between map extent and reference extent? Are they > simply used to scale between the two images? > > DF: The reference extent defines the spatial extent for the reference map. It doesn't have to be the same as the original map extent, but it makes sense that it is similar. The EXTENT defined in your map file only sets the initial map extent, the extent then changes as you zoom in, out, and pan. > > Like Steven said, one of the easy ways to learn MapServer is to get a demo (http://cvs.gis.umn.edu/dist/itasca3.5.tar.gz) working and then modify it to fit your data. There is also a tutorial at http://hypnos.cbs.umn.edu/tutorial/ > > If you haven't already looked at it, check out the MapServer New Users Page http://ms.gis.umn.edu/new_users > > Good Luck, > > David. > > Thanks in anticipation, > Stephen Davies > > -- ======================================================================== This email is for the person(s) identified above, and is confidential to the sender and the person(s). No one else is authorised to use or disseminate this email or its contents. Stephen Davies Consulting Voice: 08-8177 1595 Adelaide, South Australia. Fax: 08-8177 0133 Computing & Network solutions. Mobile:0403 0405 83
