Re: [mapguide-users] Raw GeoJson in MapGuide 4.0

2021-02-01 Thread Gunter Becker
Hi Jackie,

this works fine now. Thanks a lot. 

Gunter



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html
___
mapguide-users mailing list
mapguide-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapguide-users


Re: [mapguide-users] Raw GeoJson in MapGuide 4.0

2021-02-01 Thread Jackie Ng
Hi Gunter,

Please try this patched MgFoundation.dll

https://download.osgeo.org/mapguide/patches/MG_ticket2832/MgFoundation.7z

Extract and overwrite *all existing copies* of MgFoundation.dll in your MGOS
4.0 Preview 2 installation.

This dll contains this compiled code change:

https://trac.osgeo.org/mapguide/changeset/9826

- Jackie



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html
___
mapguide-users mailing list
mapguide-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapguide-users


Re: [mapguide-users] Raw GeoJson in MapGuide 4.0

2020-11-13 Thread Gunter Becker
Hi Jackie,

I think there is a rounding issue with the geojson format MapGuide 4 is
sending. When you have a number like for example  in your coordinates
(request with a precision set to 7) then this leads to a number with a
decimal point at the end  instead of 

You can see the original data I requested with SELECTFEATURES in this
screenshot below from developer tools. Although it is shown in web developer
console there is an error message when requesting in the browser:

SyntaxError: JSON.parse: unterminated fractional number at line 1 column 317
of the JSON data

 

So, OpenLayers doesn't show this geojson. Of course, I can choose a higher
precision to solve the issue with this specific coordinate but I have plenty
of other coordinates that have the same problem even with a higher
precision.

By the way, with MapGuide Rest the geojson output is correct.

Sorry for posting this issue here and not in trac. But there was no 4.0 in
the list of versions.

Thanks, Gunter



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html
___
mapguide-users mailing list
mapguide-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapguide-users

Re: [mapguide-users] Raw GeoJson in MapGuide 4.0

2020-11-12 Thread Gunter Becker
Thanks Jackie,

it's a bit awkward indeed, but the comment in your code kind of makes sense
when someone is really using a comma or semicolon in a property name.

Nevertheless I couldn't get it to work via the form. I tried "\t" but when
submitting the form it was translated to "%5Ct". I copied the url from the
developertools an replaced this with "\t". Didn't work either! I then put
the url in encodeUrl()-methode to encode it and finallay worked. "\t" was
translated to "%09" (the encoding for the tab character).

I appreciate your help,
Gunter



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html
___
mapguide-users mailing list
mapguide-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapguide-users

Re: [mapguide-users] Raw GeoJson in MapGuide 4.0

2020-11-12 Thread Jackie Ng
> 1. How to enter specific properties in the properties form field? I tried
> using commas, semicolons and blanks but this didn't work. Using none or
> one
> property is working.

This is a bit awkward, but the delimiter is actually the tab character (ref:
https://github.com/jumpinjackie/mapguide-maestro/blob/master/OSGeo.MapGuide.MaestroAPI/Http/RequestBuilder.cs#L554)

> 2. Ho to request a specific BBOX. Do I have to use a spatial filter in the
> filter form field

Yes, you have to pass a FDO spatial filter to the FILTER parameter, so
something to the effect of: "GeomProperty INTERSECTS GeomFromWkt('WKT of the
bbox polygon')"

Also don't forget to set VERSION=4.0.0 and CLEAN=1, otherwise you'll get the
ugly JSON that this operation previously served in the past

- Jackie



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html
___
mapguide-users mailing list
mapguide-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapguide-users