indiewebify-me icon indicating copy to clipboard operation
indiewebify-me copied to clipboard

"Check your homepage h-card" doesn't pick up u-photo unless it's nested directly under the h-card tag

Open MaybeThisIsRu opened this issue 3 years ago • 1 comments

IndieWeb IRC chat for reference.

I have my u-photo nested two or three divs under the h-card div. This causes IndieWebify.me to not pick up my photo.

When I added a hidden image directly underneath the h-card tag, IndieWebify was able to parse it.

The expectation is that no matter how far nested the u-photo or any property is, it should be parsed and picked up.You may see the current source HTML on my site.

This is a behaviour that is also mimicked by Indieweb Webring and a similar issue has been filed.

MaybeThisIsRu avatar Sep 04 '20 06:09 MaybeThisIsRu

The php-mf2 dependency is locked to quite an old version, v0.2.12. v0.4.0 fixed an issue where some h-* classes were being parsed as microformats2 when they shouldn't be. In your HTML there's class h-40 which the old parser is (incorrectly) parsing as a nested microformat inside the h-card.

Thanks for reporting this @hirusi. You can be assured that the u-photo in the nested divs is found correctly by modern parsers, so you don't have to keep the duplicate, hidden image currently. Once we update that dependency, indiewebify.me will show that nested photo.

gRegorLove avatar Sep 04 '20 08:09 gRegorLove