indieweb / micropub-extensions

Issue tracking for Micropub extensions
https://indieweb.org/Micropub-extensions
10 stars 0 forks source link

Extended GEO URI Support for Form-Encoded Posts #32

Open manton opened 4 years ago

manton commented 4 years ago

Copying this from the wiki:

Indigenous for Android has a checkin post type which passes the checkin information as additional parameters in the Geo URI. The payload property is 'geo'. It's not doing a JSON post, so you can also immediately upload pictures as well. Additional properties for the venue/location can be added later. The same technique is used to post my geocache logs, see https://indieweb.org/geocaching

geo:51.5258325,-0.1359825,0.0;name=london;url=https://hwclondon.co.uk

This is supported by:

dshanske commented 4 years ago

At the Micropub Pop-up Session 2020, it was decided to table this issue as there was no clear interest one way or the other.

dshanske commented 4 years ago

Trying to elaborate on the point of this. @swentel added this so Indigenous could submit a checkin as a form-encoded post.

In my WordPress code that consumes it, I convert this into an object using the following logic.

  1. Convert latitude, longitude, and altitude(if present as the 3rd parameter of the coordinates.) into mf2 parameters.
  2. Convert u into an accuracy parameter as mf2 has no such concept.
  3. If there is an h parameter, assume this is an h parameter, same as Micropub.
  4. Convert all other parameters to properties and create a mf2 json object.
  5. If no h property, if it only has the coordinates, assume h-geo. Otherwise,, assume h-card.