[mapguide-users] Re: Standard Viewer Measure Tool Miles to Feet

Homan, Thomas thoman at co.gila.az.us
Mon Oct 4 10:47:39 EDT 2010


Just for clarity and completeness this conversion is for the value of the International Foot (1/0.3048 = 3.280839895). If for some reason you have to deal with older US Survey Feet via program/contract requirements the conversion is 3.280833333 between meters and US survey feet. Small measurements would not show the difference but larger (>1million feet) would start to show the deviation.

Tom

-----Original Message-----
From: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] On Behalf Of Steve G
Sent: Tuesday, September 28, 2010 2:28 PM
To: mapguide-users at lists.osgeo.org
Subject: [mapguide-users] Re: Standard Viewer Measure Tool Miles to Feet


I first did this in MGOS 2.0 and documented my changes.  You just need to
follow the correct path/file names if you are using 2.1 or 2.2 which should
have installed to C:\Program Files\OSGeo
 

To change the measure tool to measure in feet:


1.  Open C:\Program
Files\MapGuideOpenSource\WebServerExtensions\www\mapviewerphp\measure.php in
text editor.  Change the conversion factor to convert from meters to feet
instead of meters to miles:

$distance *= 3.2808399; //get feet

2.  In the C:\Program
Files\MapGuideOpenSource\WebServerExtensions\www\viewerfiles\measureui.templ
file, modify the show units function to set the units var to "Feet".

From:
Line 115   var units = GetParent().GetMapFrame().IsEnglishUnits()?
"__#MILES__#": "__#KILOMETERS#__";

To:

Line 115   var units = GetParent().GetMapFrame().IsEnglishUnits()? "Feet":
"__#KILOMETERS#__";

-- 
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Standard-Viewer-Measure-Tool-Miles-to-Feet-tp1818557p5581332.html
Sent from the MapGuide Users mailing list archive at Nabble.com.
_______________________________________________
mapguide-users mailing list
mapguide-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapguide-users


More information about the mapguide-users mailing list