Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hack in h-geo support #93

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

vikanezrimaya
Copy link

This adds h-geo microformat support. It's clunky but it should work. I'm no PHP gal so I hope you have CI or something that would test it.

Test case: this post by me that should contain a checkin with h-geo embedded. Should be parsed with latitude and longitude, showing a map in applications like Monocle.

Vika added 3 commits September 8, 2019 23:18
This adds h-geo microformat support. It's clunky but it should work. I'm no PHP gal so I hope you have CI or something that would test it.

Test case: [this post by me](https://fireburn.ru/posts/1567956895) that should contain a checkin with h-geo embedded. Should be parsed with latitude and longitude, showing a map in applications like Monocle.
I'm not a PHP coder, I'm just a dummy :c
@sknebel
Copy link

sknebel commented Sep 9, 2019

I think this needs extra checks for the cases where there is not a nested object in the geo property, or if that object is malformed?

Now it checks that:
1. h-geo exists
2. it's a microformat
3. it's of type "h-geo"
4. that it has properties
5. that it has latitude
6. that it has longitude

If all checks are true, lat and lon get replaced with values of h-geo object.
@vikanezrimaya
Copy link
Author

@aaronpk @sknebel I added some more checks. Not sure if I'm using XRay functions correctly tho

@aaronpk aaronpk changed the base branch from master to main October 17, 2020 21:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants