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

parser compatibility: hentry/hreview rel=tag #157

Closed
gRegorLove opened this issue Mar 18, 2018 · 1 comment
Closed

parser compatibility: hentry/hreview rel=tag #157

gRegorLove opened this issue Mar 18, 2018 · 1 comment
Milestone

Comments

@gRegorLove
Copy link
Member

http://microformats.org/wiki/h-entry#Parser_Compatibility

rel=tag - parse as p-category. While not a class name nor typical microformats property, rel=tag was the typical way to tag an hentry. Thus parsers should look for rel=tag hyperlinks inside an hentry, and take the last path segment of their "href" value as a value for a p-category property.

Minimal example:

<div class="hentry">
  <h1 class="entry-title">Test upgrading rel=tag</h1>
  <a href="/tag/reviews" rel="tag">Reviews</a>
</div>

Current parse:

    "items": [
        {
            "type": [
                "h-entry"
            ],
            "properties": {
                "name": [
                    "Test upgrading rel=tag"
                ]
            }
        }
    ]

Expected result:

    "items": [
        {
            "type": [
                "h-entry"
            ], 
            "properties": {
                "category": [
                    "reviews"
                ], 
                "name": [
                    "Test upgrading rel=tag"
                ]
            }
        }
    ]

Confirmed mf2py is parsing this correctly.

@gRegorLove
Copy link
Member Author

Per this backcompat update, the same applies to hreview. See examples in wiki edit summary.

@gRegorLove gRegorLove changed the title parser compatibility: hentry rel=tag Mar 23, 2018
@gRegorLove gRegorLove added this to the 0.4.2 milestone Mar 23, 2018
gRegorLove added a commit to gRegorLove/php-mf2 that referenced this issue Mar 24, 2018
Update existing tests to verify rel-tag upgrade
gRegorLove added a commit to gRegorLove/php-mf2 that referenced this issue Mar 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant